https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69474
--- Comment #1 from Gerhard Steinmetz <gerhard.steinmetz.fort...@t-online.de> --- $ gfortran-5.3.1 -c z1.f90 z1.f90:19:0: z(1:n) = x([(i, i=n,1,-1)]) ^ internal compiler error: Segmentation fault --- These assignment variants are accepted : $ cat z2.f90 module m type t real :: a contains procedure :: f generic :: assignment(=) => f end type contains impure elemental subroutine f (y, x) class(t), intent(out) :: y class(t), intent(in) :: x y%a = x%a end subroutine s (x, z) class(t), allocatable :: x(:) class(t), allocatable :: z(:) integer :: i, n n = size(x) z = x z = x(1:n) z(1:n) = x z = x([(i, i=n,1,-1)]) end end