Debian Codegraph @

gcc/testsuite/gfortran.dg/interface_61.f90

raw
1 ! { dg-do compile }
2 ! { dg-options -Wexternal-argument-mismatch }
3 ! PR fortran/120163 - this used to cause an error.
4 ! Original test case by Bálint Aradi
5 module mod1
6 implicit none
7
8 abstract interface
9 pure subroutine callback_interface(a)
10 real, intent(in) :: a
11 end subroutine callback_interface
12 end interface
13
14 contains
15
16 subroutine caller(callback)
17 procedure(callback_interface) :: callback
18 real :: a
19 call callback(a)
20 end subroutine caller
21
22 end module mod1
23
24
25 module mod2
26 use mod1
27 end module mod2