https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78640
--- Comment #5 from Damian Rouson <damian at archaeologic dot codes> ---
LLVM flang also disallows the submitted code and here's a slightly shorter
reproducer that is also rejected by flang and nagfor but accepted by gfortran
and ifx:
implicit none
type foo_t
end type
contains
pure function f() result(foo)
class(foo_t), allocatable :: foo
foo = foo_t()
end function
end
