* tree-loop-distribution.c (struct partition): New field recording
[official-gcc.git] / gcc / testsuite / gfortran.dg / reshape_pad_1.f90
blob33afd89e5b36ea0808fec30b71d673faeeb56ca5
1 ! { dg-do run }
2 ! PR 38135 - pad to RESHAPE didn't work correctly when SOURCE
3 ! was an empty array.
5 program main
6 implicit none
7 integer, parameter :: N = 3
8 integer(kind=1) :: A1(N,N)
9 integer(kind=1) :: b1(n+1)
10 integer(kind=4) :: A4(n,n)
11 integer(kind=4) :: b4(n+1)
12 character(len=9) :: line
14 b1 = (/ 1, 2, 2, 2 /)
16 A1(1:N,1:N)=reshape(A1(1:0,1),(/N,N/),b1)
17 write(unit=line,fmt='(100i1)') A1
18 if (line .ne. "122212221") call abort
20 b4 = (/ 3, 4, 4, 4 /)
22 a4 = reshape(a4(:0,1),(/n,n/),b4)
23 write(unit=line,fmt='(100i1)') a4
24 if (line .ne. "344434443") call abort
25 end program main