libgfortran/ChangeLog:
[official-gcc.git] / gcc / testsuite / gfortran.dg / interface_33.f90
blob60543f9d5c92dbb637482868f66a00208769de8f
1 ! { dg-do compile }
3 ! PR fortran/33117, PR fortran/46478
4 ! Procedures of a generic interface must be either
5 ! all SUBROUTINEs or all FUNCTIONs.
9 ! PR fortran/33117
11 module m1
12 interface gen
13 subroutine sub() ! { dg-error "all SUBROUTINEs or all FUNCTIONs" }
14 end subroutine sub
15 function bar()
16 real :: bar
17 end function bar
18 end interface gen
19 end module
22 ! PR fortran/46478
24 MODULE m2
25 INTERFACE new_name
26 MODULE PROCEDURE func_name
27 MODULE PROCEDURE subr_name
28 END INTERFACE
29 CONTAINS
30 LOGICAL FUNCTION func_name() ! { dg-error "all SUBROUTINEs or all FUNCTIONs" }
31 END FUNCTION
32 SUBROUTINE subr_name()
33 END SUBROUTINE
34 END MODULE