This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/47224] ICE with procedure pointer component
- From: "m.a.hulsen at tue dot nl" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 9 Jan 2011 07:35:30 +0000
- Subject: [Bug fortran/47224] ICE with procedure pointer component
- Auto-submitted: auto-generated
- References: <bug-47224-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47224
--- Comment #1 from Martien Hulsen <m.a.hulsen at tue dot nl> 2011-01-09 07:35:28 UTC ---
The second line should be removed. Modified code:
module element_defs_m
type coefficients_t
procedure (dum_vfunc), pointer, nopass :: vfunc => null()
end type coefficients_t
contains
function dum_vfunc ( n, x )
integer, intent(in) :: n
real, intent(in), dimension(:) :: x
real, dimension(n) :: dum_vfunc
dum_vfunc = 0
end function dum_vfunc
end module element_defs_m
module poisson_elements_m
use element_defs_m
implicit none
contains
subroutine poisson_natboun_surface ( coefficients )
type(coefficients_t), intent(in) :: coefficients
real, allocatable, dimension(:) :: xg, normal
real :: a
integer :: ndim = 3
a = dot_product ( normal, coefficients%vfunc ( ndim, xg(:) ) )
end subroutine poisson_natboun_surface
end module poisson_elements_m