diff options
author | aldot <aldot@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-04-18 17:58:41 +0000 |
---|---|---|
committer | aldot <aldot@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-04-18 17:58:41 +0000 |
commit | 4ccfeca17118c11267f85c40cc38497ab6aeb094 (patch) | |
tree | ea673eafaa5e0941cdff1244be943f0655791326 | |
parent | bc52acac27ea3820acf7395dfdb66def35107c60 (diff) | |
download | gcc-4ccfeca17118c11267f85c40cc38497ab6aeb094.tar.gz |
fortran/
* parse.c (next_free): Use consistent error string between
free-form and fixed-form for illegal statement label of zero.
(next_fixed): Use consistent warning string between free-form
and fixed-form for statement labels for empty statements.
testsuite/
* gfortran.dg/label_1.f90: Adjust dg-error.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@113053 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/fortran/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/fortran/parse.c | 6 | ||||
-rw-r--r-- | gcc/testsuite/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/testsuite/gfortran.dg/label_1.f90 | 2 |
4 files changed, 15 insertions, 4 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 01b8071b78f..c9547172fb6 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,10 @@ +2006-04-18 Bernhard Fischer <aldot@gcc.gnu.org> + + * parse.c (next_free): Use consistent error string between + free-form and fixed-form for illegal statement label of zero. + (next_fixed): Use consistent warning string between free-form + and fixed-form for statement labels for empty statements. + 2006-04-18 Steve Ellcey <sje@cup.hp.com> * trans-io.c (gfc_build_io_library_fndecls): Align pad. diff --git a/gcc/fortran/parse.c b/gcc/fortran/parse.c index b120bbb77ef..5fb9ce12457 100644 --- a/gcc/fortran/parse.c +++ b/gcc/fortran/parse.c @@ -428,9 +428,9 @@ next_free (void) if (cnt > 5) gfc_error_now ("Too many digits in statement label at %C"); - + if (c == 0) - gfc_error_now ("Statement label at %C is zero"); + gfc_error_now ("Zero is not a valid statement label at %C"); do c = gfc_next_char (); @@ -600,7 +600,7 @@ next_fixed (void) blank_line: if (digit_flag) - gfc_warning ("Statement label in blank line will be ignored at %C"); + gfc_warning ("Ignoring statement label in empty statement at %C"); gfc_advance_line (); return ST_NONE; } diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 32e2d114b62..e48bc78add3 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2006-04-18 Bernhard Fischer <aldot@gcc.gnu.org> + + * gfortran.dg/label_1.f90: Adjust dg-error. + 2006-04-16 Roger Sayle <roger@eyesopen.com> PR target/26961 diff --git a/gcc/testsuite/gfortran.dg/label_1.f90 b/gcc/testsuite/gfortran.dg/label_1.f90 index 149c79f1029..94f3b5e61ad 100644 --- a/gcc/testsuite/gfortran.dg/label_1.f90 +++ b/gcc/testsuite/gfortran.dg/label_1.f90 @@ -3,7 +3,7 @@ program a 0056780 continue ! { dg-error "Too many digits" } -0 continue ! { dg-error "Statement label at" } +0 continue ! { dg-error "Zero is not a valid statement label" } stop 001234 ! { dg-error "Too many digits" } end program a |