diff options
author | Fritz Reese <fritzoreese@gmail.com> | 2016-10-25 15:24:36 +0000 |
---|---|---|
committer | Fritz Reese <foreese@gcc.gnu.org> | 2016-10-25 15:24:36 +0000 |
commit | 90051c26da7abd0999ce0afdd9471e354009b861 (patch) | |
tree | e01b0eb63f28905e753fbf1c8cd6160907cdfc2b /gcc/fortran/match.c | |
parent | ef14476730875df063a5788a0072984e22b7c2ec (diff) | |
download | gcc-90051c26da7abd0999ce0afdd9471e354009b861.zip gcc-90051c26da7abd0999ce0afdd9471e354009b861.tar.gz gcc-90051c26da7abd0999ce0afdd9471e354009b861.tar.bz2 |
Support TYPE as alias for PRINT with -fdec.
gcc/fortran/
* decl.c (gfc_match_type): New function.
* match.h (gfc_match_type): New function.
* match.c (gfc_match_if): Special case for one-line IFs.
* gfortran.texi: Update documentation.
* parse.c (decode_statement): Invoke gfc_match_type.
gcc/testsuite/gfortran.dg/
* dec_type_print.f90: New testcase.
From-SVN: r241518
Diffstat (limited to 'gcc/fortran/match.c')
-rw-r--r-- | gcc/fortran/match.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/fortran/match.c b/gcc/fortran/match.c index aa9961c..236231e 100644 --- a/gcc/fortran/match.c +++ b/gcc/fortran/match.c @@ -1622,6 +1622,9 @@ gfc_match_if (gfc_statement *if_type) match ("where", match_simple_where, ST_WHERE) match ("write", gfc_match_write, ST_WRITE) + if (flag_dec) + match ("type", gfc_match_print, ST_WRITE) + /* The gfc_match_assignment() above may have returned a MATCH_NO where the assignment was to a named constant. Check that special case here. */ |