[Bug fortran/34392] BOZ diagnost invalid Fortran 2003 use with -std=f2003 warnings

burnus at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Mon Dec 17 09:49:00 GMT 2007



------- Comment #1 from burnus at gcc dot gnu dot org  2007-12-17 09:49 -------
NOTE: The Fortran 2003 has the specific function (of generic REAL) FLOAT and
SNGL for which BOZ are not allowed.

FLOAT takes the same code path as REAL (w/o kind argument). With -std=f2003 a
BOZ in FLOAD should be rejected.

For SNGL: It will probably solved by PR 34505, which should allow only real
arguments for SNGL.

Currently, the gfortran documentation has:

"Since Fortran 2003 BOZ literals are also allowed as argument of REAL, DBLE,
INT and CMPLX; the result is the same as if the integer BOZ literal had been
converted by TRANSFER [...] The GNU Fortran intrinsic procedure FLOAT, DFLOAT,
COMPLEX and DCMPLX are treated alike."
http://gcc.gnu.org/onlinedocs/gfortran/BOZ-literal-constants.html


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34392



More information about the Gcc-bugs mailing list