Default missing exponents to 0 with -fdec.
authorFritz Reese <fritzoreese@gmail.com>
Thu, 3 Nov 2016 18:09:44 +0000 (18:09 +0000)
committerFritz Reese <foreese@gcc.gnu.org>
Thu, 3 Nov 2016 18:09:44 +0000 (18:09 +0000)
commit6869e9c69f446161edba48722a75813934643382
tree4b3e9356f44befe3d696e42639572508aa2db76c
parent1bac673faf4a0a0bd0a5606dad9d98b33d568510
Default missing exponents to 0 with -fdec.

gcc/fortran/
* gfortran.texi: Document.
* gfortran.h (gfc_dt): New field default_exp.
* primary.c (match_real_constant): Default exponent with -fdec.
* io.c (match_io): Set dt.default_exp with -fdec.
* ioparm.def (IOPARM_dt_default_exp): New.
* trans-io.c (build_dt): Set IOPARM_dt_default_exp with -fdec.

libgfortran/io/
* io.h (IOPARM_DT_DEFAULT_EXP): New flag bit.
* list_read.c (parse_real, read_real): Allow omission of exponent with
IOPARM_DT_DEFAULT_EXP.
* read.c (read_f): Ditto.

gcc/testsuite/gfortran.dg/
* dec_exp_1.f90, dec_exp_2.f90, dec_exp_3.f90: New testcases.

From-SVN: r241828
15 files changed:
gcc/fortran/ChangeLog
gcc/fortran/gfortran.h
gcc/fortran/gfortran.texi
gcc/fortran/io.c
gcc/fortran/ioparm.def
gcc/fortran/primary.c
gcc/fortran/trans-io.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/dec_exp_1.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/dec_exp_2.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/dec_exp_3.f90 [new file with mode: 0644]
libgfortran/ChangeLog
libgfortran/io/io.h
libgfortran/io/list_read.c
libgfortran/io/read.c