RISC-V: Regenerate opt urls.
[official-gcc.git] / gcc / testsuite / gfortran.dg / use_5.f90
bloba9c099468031ccc0729a93e74d8a39d69a931bcf
1 ! { dg-do run }
2 ! Renaming of operators
3 module z
4 interface operator(.addfive.)
5 module procedure sub2
6 end interface
7 contains
8 function sub2(x)
9 integer :: sub
10 integer,intent(in) :: x
11 sub2 = x + 5
12 end function sub2
13 end module z
15 module y
16 interface operator(.addfive.)
17 module procedure sub
18 end interface
19 contains
20 function sub(x)
21 integer :: sub
22 integer,intent(in) :: x
23 sub = x + 15
24 end function sub
25 end module y
27 module x
28 interface operator(.addfive.)
29 module procedure sub
30 end interface
31 contains
32 function sub(x)
33 integer :: sub
34 integer,intent(in) :: x
35 sub = x + 25
36 end function sub
37 end module x
39 use x, only : operator(.bar.) => operator(.addfive.)
40 use y, operator(.my.) => operator(.addfive.)
41 use z
42 integer :: i
43 i = 2
44 if ((.bar. i) /= 2+25) STOP 1
45 if ((.my. i) /= 2+15) STOP 2
46 if ((.addfive. i) /= 2+5) STOP 3
47 end