modula2: Simplify REAL/LONGREAL/SHORTREAL node creation.
[official-gcc.git] / gcc / testsuite / gfortran.dg / derived_init_5.f90
blobb94ca39ce026d70bde7a57ccc5d09b2aaab08a81
1 ! { dg-do run }
2 ! PR 59781 - this was not initialized correctly before.
3 ! Original test case by James Spencer.
4 implicit none
6 type t1
7 integer :: s
8 end type
10 type t2
11 type(t1) :: state = t1(1)
12 real, allocatable :: store(:)
13 end type
15 call test
17 contains
19 subroutine test
20 type(t2) :: rng
21 if (rng%state%s /= 1) STOP 1
22 end subroutine
24 end