Debian Codegraph @

gcc/testsuite/gfortran.dg/constant_shape.f90

raw
1 ! { dg-do compile }
2 !
3 ! PR 78392: ICE in gfc_trans_auto_array_allocation, at fortran/trans-array.c:5979
4 !
5 ! Contributed by Janus Weil <[email protected]>
6 ! Error message update with patch for PR fortran/83633
7 !
8 module mytypes
9 implicit none
10 contains
11 pure integer function get_i ()
12 get_i = 13
13 end function
14 end module
15
16 program test
17 use mytypes
18 implicit none
19 integer, dimension(get_i()) :: x ! { dg-error "array with nonconstant bounds" }
20 print *, size (x) ! { dg-error "has no IMPLICIT type" }
21 end