https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60913
--- Comment #6 from Damian Rouson <damian at sourceryinstitute dot org> --- I don't have any specific knowledge of it being fixed, but there have been two releases since 6.1.0: the latest is 6.3.0 and 7.1.0 is expected to be released soon so the current trunk is a nearly releasable state. In case it helps, both 6.3.0 and a relatively recent build of 7.0.0 are available in the virtual machine here: www.sourceryinstitute.org/store. On a separate note, I am in the process of trying to decide about whether I will continue to use allocatable polymorphic function results because they are not allowed in pure functions of which I'm a big fan both for code clarity and potential performance benefits and especially for the ease with which one can parallelize expressions comprised of operators implemented as pure functions. Last, FORALL will be declared obsolescent in Fortran 2015. In the example that you posted, I recommend considering DO CONCURRENT as a replacement wherever possible. Damian