OSDN Git Service

* gfortran.h (struct gfc_symbol): Add equiv_built.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gfortran.fortran-torture / execute / module_interface_2.f90
1 ! 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