[patch,fortran] Give an error when using non-integers with BOZ edit descriptors with -std=f* (PR29625)

Jerry DeLisle jvdelisle@verizon.net
Sat Oct 28 22:06:00 GMT 2006


Tobias Burnus wrote:
> :ADDPATCH fortran:
> 
> Fortran 95 and Fortran 2003 only allow BOZ edit descriptors for
> integers. gfortran accepts as extension also OZ edit descriptors for
> non-integers, even when using -std=f95/-std=f2003.
> 
> See PR29625 and also
> http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/231b28d62ed52d2b
> 
> (Let's see what Fortran 2008 will do. Fortran 2003 gave us real BOZ
> (e.g. "real(z'FFFFF')"); it would then only be consequent to allow using
> them with BOZ edit descriptors.)
> 
> This patch allows to use binary edit descriptors for non-integers (for
> octal and hexadecimal it was allowed) and gives an error for -std=f95
> and -std=f2003.
> 
> The output is actually the same for the real variables as in ifort;
> ifort, however, fails with character variables("insufficient virtual
> memory"). NAG f95, g95 and sunf95 don't accept BOZ edit descriptors for
> reals.
> 
> Tobias
> 
> 
> 2006-10-28  Tobias Burnus  <burnus@net-b.de>
> 
>     PR fortran/29625
>     * io/transfer.c (formatted_transfer_scalar): Allow binary edit
>       descriptors for real variables; give error for BOZ edit
>       descriptor for non-integers when using -std=f*.
> 
> 
> 2006-10-28  Tobias Burnus  <burnus@net-b.de>
> 
>     PR fortran/29625
>     * gfortran.dg/io_real_boz.f90: Add.
>     * gfortran.dg/io_real_boz2.f90: Add.
> 
> 
This is OK to commit to 4.3

I regression tested on i686-linux, NIST tested.  On future submittals please 
specify the testing you did and the platform you tested on.

Thanks,

Jerry



More information about the Gcc-patches mailing list