1! { dg-do compile }
2!
3! PR 59143: [OOP] Bogus warning with array-valued type-bound procedure
4!
5! Contributed by Jürgen Reuter <juergen.reuter@desy.de>
6
7module phs_single
8
9  type :: phs_single_t
10   contains
11     procedure, nopass :: d1, d2
12  end type
13
14contains
15
16  subroutine evaluate (phs)
17    class(phs_single_t) :: phs
18    call func1 (phs%d1 ())
19    call func1 (phs%d2 (2))
20  end subroutine
21
22  subroutine func1 (p)
23    real :: p(2)
24  end subroutine
25
26  function d1 ()
27    real :: d1(2)
28    d1 = 1.
29  end function
30
31  function d2 (n)
32    real :: d2(n)
33    d2 = 1.
34  end function
35
36end module
37
38! { dg-final { cleanup-modules "phs_single" } }
39