This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/42051] ICE on allocatable array TBP result
- From: "janus at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 15 Nov 2009 18:30:32 -0000
- Subject: [Bug fortran/42051] ICE on allocatable array TBP result
- References: <bug-42051-15301@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from janus at gcc dot gnu dot org 2009-11-15 18:30 -------
(In reply to comment #0)
> field_grid.f03:27:0: internal compiler error: in gfc_conv_variable, at
> fortran/trans-expr.c:550
Here is a reduced test case which gives the same ICE:
type grid
end type
contains
function return_x(this) result(this_x)
class(grid) :: this
real ,dimension(1) :: this_x
end function
subroutine output()
type(grid) :: mesh
real ,dimension(1) :: x
x = return_x(mesh)
end subroutine
end
So it seems this is neither connected to TBPs, nor to ALLOCATABLE.
The ICE goes away however, if I remove the DIMENSION attributes, or if I make
the CLASS argument a TYPE.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42051