PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gfortran.dg / typebound_generic_10.f03
blob56952e1b90156da3ba4d060e4cfad99375cf0c9f
1 ! { dg-do compile }
3 ! PR 49196: [OOP] gfortran compiles invalid generic TBP: dummy arguments are type compatible
5 ! Contributed by Hans-Werner Boschmann <boschmann@tp1.physik.uni-siegen.de>
7 module generic
9   type :: a_type
10    contains
11      procedure :: a_subroutine
12   end type a_type
14   type,extends(a_type) :: b_type
15    contains
16      procedure :: b_subroutine
17      generic :: g_sub => a_subroutine,b_subroutine  ! { dg-error "are ambiguous" }
18   end type b_type
20 contains
22   subroutine a_subroutine(this)
23     class(a_type)::this
24   end subroutine a_subroutine
26   subroutine b_subroutine(this)
27     class(b_type)::this
28   end subroutine b_subroutine
30 end module generic