Implementation of #339
Merge pull request #340 from emmanuel-keller/1.5

Implementation of #339