c: Fix up pointer types to may_alias structures [PR114493]
[official-gcc.git] / gcc / testsuite / gfortran.dg / parameter_array_dummy.f90
blob057beaa7cc2f4ee29c4732eddd4863b2caaae984
1 ! { dg-do run }
2 ! PR fortran/31188
3 program foo_mod
4 implicit none
5 character (len=1), parameter :: letters(2) = (/"a","b"/)
6 call concat(1, [1])
7 call concat(2, [2])
8 call concat(3, [1,2])
9 call concat(4, [2,1])
10 call concat(5, [2,2,2])
11 contains
12 subroutine concat(i, ivec)
13 integer, intent(in) :: i, ivec(:)
14 write (*,*) i, "a" // letters(ivec)
15 end subroutine concat
16 end program foo_mod
17 ! { dg-output " *1 aa(\r*\n+)" }
18 ! { dg-output " *2 ab(\r*\n+)" }
19 ! { dg-output " *3 aaab(\r*\n+)" }
20 ! { dg-output " *4 abaa(\r*\n+)" }
21 ! { dg-output " *5 ababab(\r*\n+)" }