* cfgloopmanip.c (duplicate_loop_to_header_edge): Cleanup profile
[official-gcc.git] / gcc / testsuite / gfortran.dg / derived_constructor_char_3.f90
blobe23878541bbed64d367909c31f951e97c8dccbe6
1 ! { dg-do compile }
3 ! PR fortran/51966
5 ! Contributed by Peter Wind
8 type :: Deriv
9 character(len=10) :: name
10 end type
11 character(len=8), dimension(2), parameter :: &
12 DEF_ECOSYSTEMS = (/ "Gridxxxx", "StringYY" /)
14 type(Deriv), save :: DepEcoSystem = Deriv(DEF_ECOSYSTEMS(1))
16 if (DepEcoSystem%name /= "Gridxxxx" &
17 .or. DepEcoSystem%name(9:9) /= ' ' &
18 .or. DepEcoSystem%name(10:10) /= ' ') call abort()
19 DepEcoSystem%name = 'ABCDEFGHIJ'
20 call Init_EcoSystems()
21 if (DepEcoSystem%name /= "StringYY" &
22 .or. DepEcoSystem%name(9:9) /= ' ' &
23 .or. DepEcoSystem%name(10:10) /= ' ') call abort()
25 contains
26 subroutine Init_EcoSystems()
27 integer :: i =2
28 DepEcoSystem = Deriv(DEF_ECOSYSTEMS(i))
29 end subroutine Init_EcoSystems
30 end