Debian Codegraph @

gcc/testsuite/gfortran.dg/proc_ptr_comp_37.f90

raw
1 ! { dg-do compile }
2 !
3 ! PR 56385: [4.6/4.7/4.8 Regression] [OOP] ICE with allocatable function result in a procedure-pointer component
4 !
5 ! Contributed by Vladimir Fuka <[email protected]>
6
7 implicit none
8
9 type :: TGeometricShape
10 end type
11
12 type :: TVolumeSourceBody
13 class(TGeometricShape), allocatable :: GeometricShape
14 procedure(scalar_flux_interface), pointer :: get_scalar_flux
15 end type
16
17 abstract interface
18 function scalar_flux_interface(self) result(res)
19 import
20 real, allocatable :: res(:)
21 class(TVolumeSourceBody), intent(in) :: self
22 end function
23 end interface
24
25 end