PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gfortran.dg / array_constructor_1.f90
blob7654c10046a698aeefc5f63623ad3583b95e6124
1 ! { dg-do run }
2 ! Check that [...] style array constructors work
3 program bracket_array_constructor
4 implicit none
5 integer :: a(4), i
7 a = [ 1, 2, 3, 4 ]
8 do i = 1, size(a)
9 if (a(i) /= i) STOP 1
10 end do
12 a = [ (/ 1, 2, 3, 4 /) ]
13 do i = 1, size(a)
14 if (a(i) /= i) STOP 2
15 end do
17 end program bracket_array_constructor