This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: ICE with non-allocatable CLASS variable
- From: Tobias Burnus <tobias dot burnus at physik dot fu-berlin dot de>
- To: Andrew Benson <abenson at its dot caltech dot edu>, fortran at gcc dot gnu dot org
- Date: Wed, 15 Jun 2011 09:39:55 +0200
- Subject: Re: ICE with non-allocatable CLASS variable
Hi Andrew,
Andrew Benson wrote:
> The following gives an ICE with gfortran 4.7.0 r175063.
> It's not legal Fortran
I concur:
F2008's "4.3.1.1 Type specifier syntax" has:
C407 An entity declared with the CLASS keyword shall be a dummy
argument or have the ALLOCATABLE or POINTER attribute.
> I haven't found this in bugzilla but wanted to double check that
> this isn't a known problem before submitting a bug report.
I glanced at Bugzilla and couldn't find it neither.
When compiling your program, I get a segmentation fault and
Valgrind shows:
==15300== Invalid read of size 1
==15300== at 0x502B83: parse_spec (parse.c:2110)
==15300== by 0x503B42: gfc_parse_file (parse.c:4113)
==15300== by 0x53D3F5: gfc_be_parse_file (f95-lang.c:250)
Which is parse_derived's
2109 default:
2110 unexpected_statement (st);
Tobias