URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 302 |
Rev 384 |
! { dg-do compile }
|
! { dg-do compile }
|
! One of the tests of the patch for PR30068.
|
! One of the tests of the patch for PR30068.
|
! Taken from comp.lang.fortran 3rd December 2006.
|
! Taken from comp.lang.fortran 3rd December 2006.
|
!
|
!
|
! Although the generic procedure is not referenced and it would
|
! Although the generic procedure is not referenced and it would
|
! normally be permissible for it to be ambiguous, the USE, ONLY
|
! normally be permissible for it to be ambiguous, the USE, ONLY
|
! statement is effectively a reference and is invalid.
|
! statement is effectively a reference and is invalid.
|
!
|
!
|
module mod1
|
module mod1
|
interface generic
|
interface generic
|
subroutine foo(a)
|
subroutine foo(a)
|
real :: a
|
real :: a
|
end subroutine
|
end subroutine
|
end interface generic
|
end interface generic
|
end module mod1
|
end module mod1
|
|
|
module mod2
|
module mod2
|
interface generic
|
interface generic
|
subroutine bar(a)
|
subroutine bar(a)
|
real :: a
|
real :: a
|
end subroutine
|
end subroutine
|
end interface generic
|
end interface generic
|
end module mod2
|
end module mod2
|
|
|
program main
|
program main
|
use mod1, only: generic ! { dg-warning "has ambiguous interfaces" }
|
use mod1, only: generic ! { dg-warning "has ambiguous interfaces" }
|
use mod2
|
use mod2
|
end program main
|
end program main
|
|
|
! { dg-final { cleanup-modules "mod1 mod2" } }
|
! { dg-final { cleanup-modules "mod1 mod2" } }
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.