URL
https://opencores.org/ocsvn/scarts/scarts/trunk
Subversion Repositories scarts
[/] [scarts/] [trunk/] [toolchain/] [scarts-gcc/] [gcc-4.1.1/] [gcc/] [testsuite/] [gfortran.fortran-torture/] [execute/] [intrinsic_spread.f90] - Rev 12
Compare with Previous | Blame | View Log
program foo
integer, dimension (2, 3) :: a
integer, dimension (2, 2, 3) :: b
character (len=80) line1, line2, line3
a = reshape ((/1, 2, 3, 4, 5, 6/), (/2, 3/))
b = spread (a, 1, 2)
if (any (b .ne. reshape ((/1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6/), &
(/2, 2, 3/)))) &
call abort
write(line1, 9000) b
write(line2, 9000) spread (a, 1, 2)
if (line1 /= line2) call abort
write(line3, 9000) spread (a, 1, 2) + 0
if (line1 /= line3) call abort
9000 format(12I3)
end program