PR middle-end/77674
[official-gcc.git] / gcc / testsuite / gfortran.dg / constant_shape.f90
blobc2eaf82f5ec7766a014b74fb25a9ddbea38fa279
1 ! { dg-do compile }
3 ! PR 78392: ICE in gfc_trans_auto_array_allocation, at fortran/trans-array.c:5979
5 ! Contributed by Janus Weil <janus@gcc.gnu.org>
7 module mytypes
8 implicit none
9 contains
10 pure integer function get_i ()
11 get_i = 13
12 end function
13 end module
15 program test
16 use mytypes
17 implicit none
18 integer, dimension(get_i()) :: x ! { dg-error "must have constant shape" }
19 print *, size (x)
20 end