Retro68/gcc/gcc/testsuite/gfortran.dg/generic_34.f90
Wolfgang Thaller 6fbf4226da gcc-9.1
2019-06-20 20:10:10 +02:00

28 lines
532 B
Fortran

! { dg-do compile }
!
! PR 86116: [6/7/8/9 Regression] Ambiguous generic interface not recognised
!
! Contributed by martin <mscfd@gmx.net>
module mod
type :: t
end type t
interface sub
module procedure s1
module procedure s2
end interface
contains
subroutine s1(x) ! { dg-error "Ambiguous interfaces in generic interface" }
type(t) :: x
end subroutine
subroutine s2(x) ! { dg-error "Ambiguous interfaces in generic interface" }
class(*), allocatable :: x
end subroutine
end