aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/io.c
diff options
context:
space:
mode:
authorAndrew Pinski <pinskia@physics.uc.edu>2005-04-09 18:44:07 +0000
committerAndrew Pinski <pinskia@gcc.gnu.org>2005-04-09 11:44:07 -0700
commit53d8a8ac22f1da70288ba496a0f63ca26f3e70dd (patch)
treec994c1aa2ba0c5a038c6f170fcd097a4bd19d085 /gcc/fortran/io.c
parent9d30f3c190d89f886600bd4ccfe33d62d78adc51 (diff)
downloadgcc-53d8a8ac22f1da70288ba496a0f63ca26f3e70dd.zip
gcc-53d8a8ac22f1da70288ba496a0f63ca26f3e70dd.tar.gz
gcc-53d8a8ac22f1da70288ba496a0f63ca26f3e70dd.tar.bz2
re PR fortran/13257 ([4.0 only] Error instead of warning for missing comma in format string)
PR fortran/13257 fortran/ChangeLog: * io.c (check_format): Allow an optional comma between descriptors. libgfortran/ChangeLog: * format.c (parse_format_list): Allow an optional comma between descriptors. testsuite/ChangeLog: * comma_format_extension_[1234].f: New tests. From-SVN: r97919
Diffstat (limited to 'gcc/fortran/io.c')
-rw-r--r--gcc/fortran/io.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/fortran/io.c b/gcc/fortran/io.c
index 12650f9..90eb855 100644
--- a/gcc/fortran/io.c
+++ b/gcc/fortran/io.c
@@ -433,6 +433,7 @@ check_format (void)
format_item:
/* In this state, the next thing has to be a format item. */
t = format_lex ();
+format_item_1:
switch (t)
{
case FMT_POSINT:
@@ -701,8 +702,10 @@ between_desc:
goto syntax;
default:
- error = "Missing comma";
- goto syntax;
+ if (gfc_notify_std (GFC_STD_GNU, "Extension: Missing comma at %C")
+ == FAILURE)
+ return FAILURE;
+ goto format_item_1;
}
optional_comma: