OpenCores
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_merge.f90] - Blame information for rev 12

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 12 jlechner
! Program to test the MERGE intrinsic
2
program intrinsic_merge
3
   integer, dimension(3) :: a, b
4
   integer i
5
 
6
   a = (/-1, 2, 3/)
7
 
8
   i = 5
9
   if (merge (-1, 1, i .gt. 3) .ne. -1) call abort
10
   i = 1
11
   if (merge (-1, 1, i .ge. 3) .ne. 1) call abort
12
 
13
   b = merge(a, 0, a .ge. 0)
14
   if (any (b .ne. (/0, 2, 3/))) call abort
15
end program

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.