aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/interface_61.f90
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gfortran.dg/interface_61.f90')
-rw-r--r--gcc/testsuite/gfortran.dg/interface_61.f9027
1 files changed, 27 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/interface_61.f90 b/gcc/testsuite/gfortran.dg/interface_61.f90
new file mode 100644
index 0000000..15db3b8a
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/interface_61.f90
@@ -0,0 +1,27 @@
+! { dg-do compile }
+! { dg-options -Wexternal-argument-mismatch }
+! PR fortran/120163 - this used to cause an error.
+! Original test case by Bálint Aradi
+module mod1
+ implicit none
+
+ abstract interface
+ pure subroutine callback_interface(a)
+ real, intent(in) :: a
+ end subroutine callback_interface
+ end interface
+
+contains
+
+ subroutine caller(callback)
+ procedure(callback_interface) :: callback
+ real :: a
+ call callback(a)
+ end subroutine caller
+
+end module mod1
+
+
+module mod2
+ use mod1
+end module mod2