fix pr/45972
[official-gcc.git] / gcc / testsuite / gfortran.dg / assumed_size_dt_dummy.f90
blob1f45f24ed30296c6bae355ebaa1b00c32f3409db
1 ! { dg-do compile }
2 ! PR20853 - No array size information for initializer.
3 ! PR24440 - patch for PR20853 caused a segfault at line 12.
4 ! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
5 MODULE TEST
6 TYPE init
7 INTEGER :: I=0
8 END TYPE init
9 CONTAINS
10 SUBROUTINE try (A, B) ! { dg-error "cannot have a default initializer" }
11 TYPE(init), DIMENSION(*), INTENT(OUT) :: A
12 TYPE(init) , INTENT(OUT) :: B ! PR24440 => segfault
13 END SUBROUTINE try
14 END MODULE TEST
16 end
18 ! { dg-final { cleanup-modules "TEST" } }