computed array declarations
Tobias.Schlueter@Physik.Uni-Muenchen.DE
Tobias.Schlueter@Physik.Uni-Muenchen.DE
Thu Nov 3 09:29:00 GMT 2005
Quoting Manfred Schwarb <manfred99@gmx.ch>:
> my pet bug http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18271
> got just its first anniversary.
> That's no problem for me, as this is rather a minor issue
> and is easy to circumvent.
>
> However, I still wonder why
> SUBROUTINE SPFFT1(IMAX)
> INTEGER,INTENT(IN):: IMAX
> REAL:: AUX1(25000+INT(0.82*IMAX))
>
> should be invalid code (as declared in the bugzilla), I have seen
> several such constructs in fortran codes. Could someone please
> enlighten me?
>
> If it's invalid code, then
> REAL:: AUX1(25000+INT(0.82*float(IMAX)))
>
> is probably invalid too, but gfortran compiles it just fine.
> Should I file a bug report?
I gave a reason in the PR why it's invalid, but I'm in the office right now and
don't have the standard at hand to verify that I didn't mess up when I wrote
that. Admittedly, this extension shouldn't be difficult to implement.
- Tobi
More information about the Fortran
mailing list