aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gfortran.dg/typebound_call_23.f03
blob: 5baa26179d4908bd582d8b64cf18e5e1689b8f51 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
! { dg-do compile }
!
! PR 52968: [OOP] Call to type-bound procedure wrongly rejected
!
! Contributed by Reuben Budiardja <reubendb@gmail.com>

module SolverModule

 type :: SolverType
   class ( EquationTemplate ), pointer :: Equation
 end type

 type :: EquationTemplate
 contains
   procedure, nopass :: Evaluate
 end type

contains

  subroutine Evaluate ()
  end subroutine

 subroutine Solve
   type ( SolverType ) :: S
   call S % Equation % Evaluate ()
 end subroutine

end module