diff options
Diffstat (limited to 'gcc/fortran/io.c')
-rw-r--r-- | gcc/fortran/io.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/gcc/fortran/io.c b/gcc/fortran/io.c index 6311972..5db519a 100644 --- a/gcc/fortran/io.c +++ b/gcc/fortran/io.c @@ -2146,8 +2146,12 @@ loop: get_io_list: /* Optional leading comma (non-standard). */ - if (!comma_flag) - gfc_match_char (','); + if (!comma_flag + && gfc_match_char (',') == MATCH_YES + && k == M_WRITE + && gfc_notify_std (GFC_STD_GNU, "Comma before output item list " + "at %C is an extension") == FAILURE) + return MATCH_ERROR; io_code = NULL; if (gfc_match_eos () != MATCH_YES) |