URL
https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk
Subversion Repositories openrisc_me
[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gfortran.dg/] [entry_9.f90] - Rev 312
Go to most recent revision | Compare with Previous | Blame | View Log
! { dg-do run }
! Check whether RESULT of ENTRY defaults to entry-name.
! PR fortran/30873
!
! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
!
MODULE M1
CONTAINS
FUNCTION F2(K)
INTEGER :: F2,K
F2=E1(K)
END FUNCTION F2
RECURSIVE FUNCTION F1(I)
INTEGER :: F1,I,E1
F1=F2(I)
RETURN
ENTRY E1(I)
E1=-I
RETURN
END FUNCTION F1
END MODULE M1
program main
use m1
if (E1(5) /= -5) call abort()
if (F2(4) /= -4) call abort()
if (F1(1) /= -1) call abort()
end program main
! { dg-final { cleanup-modules "m1" } }
Go to most recent revision | Compare with Previous | Blame | View Log