1! { dg-do compile }
2!
3! PR 53328: [OOP] Ambiguous check for type-bound GENERIC shall ignore PASSed arguments
4!
5! Contributed by Salvatore Filippone <filippone.salvatore@gmail.com>
6
7module m
8  type t
9  contains
10    procedure, pass(this) :: sub1
11    procedure, pass(this) :: sub2
12    generic :: gen => sub1, sub2   ! { dg-error "are ambiguous" }
13  end type t
14contains
15  subroutine sub1 (x, this)
16    integer :: i
17    class(t) :: this
18  end subroutine sub1
19
20  subroutine sub2 (this, y)
21    integer :: i
22    class(t) :: this
23  end subroutine sub2
24end module m 
25
26! { dg-final { cleanup-modules "m" } }
27