diff options
Diffstat (limited to 'gcc/fortran')
-rw-r--r-- | gcc/fortran/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/fortran/decl.c | 7 |
2 files changed, 11 insertions, 1 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index ea08640..112fc36d 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2005-01-07 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de> + + * decl.c (gfc_match_function_decl): Correctly error out in case of + omitted function argument list. + 2006-01-07 Paul Thomas <pault@gcc.gnu.org> PR fortran/22146 diff --git a/gcc/fortran/decl.c b/gcc/fortran/decl.c index 1358cdcf..1d20a0d 100644 --- a/gcc/fortran/decl.c +++ b/gcc/fortran/decl.c @@ -2548,7 +2548,12 @@ gfc_match_function_decl (void) m = gfc_match_formal_arglist (sym, 0, 0); if (m == MATCH_NO) - gfc_error ("Expected formal argument list in function definition at %C"); + { + gfc_error ("Expected formal argument list in function " + "definition at %C"); + m = MATCH_ERROR; + goto cleanup; + } else if (m == MATCH_ERROR) goto cleanup; |