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/] [module_interface_2.f90] - Blame information for rev 12

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 12 jlechner
! Test generic interfaces declared in modules.
2
! We used to get the name mangling wrong for these.
3
module module_interface_2
4
  interface foo
5
    subroutine myfoo (i)
6
      integer i
7
    end subroutine
8
    module procedure bar
9
  end interface
10
contains
11
subroutine bar (r)
12
  real r
13
 
14
  if (r .ne. 1.0) call abort ()
15
end subroutine
16
end module
17
 
18
subroutine myfoo (i)
19
  integer i
20
 
21
  if (i .ne. 42) call abort ()
22
end subroutine
23
 
24
program test
25
  use module_interface_2
26
 
27
  call foo (42)
28
  call foo (1.0)
29
end program

powered by: WebSVN 2.1.0

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