2 ! Test assignments of nested derived types with allocatable components(PR 20541).
4 ! Contributed by Erik Edelmann <eedelmann@gcc.gnu.org>
5 ! and Paul Thomas <pault@gcc.gnu.org>
8 integer, allocatable
:: i(:)
12 type (a
), allocatable
:: at(:)
20 x(2) = a((/1,2,3,4/)+10)
22 y(1) = b((/x(1),x(2)/))
23 y(2) = b((/x(2),x(1)/))
26 forall (j
=1:2,k
=1:4, y(1)%at(j
)%i(k
) .ne
. y(2)%at(j
)%i(k
)) &
28 if (any ((/((y(1)%at(j
)%i(k
), k
=1,4),j
=1,2)/) .eq
. 999)) call abort ()
32 forall (i
=1:2,j
=1:2,k
=1:4, z(i
)%at(j
)%i(k
) .ne
. y(i
)%at(j
)%i(k
)) &
34 if (any ((/(((z(i
)%at(j
)%i(k
), k
=1,4),j
=1,2),i
=1,2)/) .eq
. 999)) call abort ()