2001-03-21 Jakub Jelinek * lex.c (ffelex_hash_): Avoid eating one whole line after #line. * g77.f-torture/compile/20010321-1.f: New test. --- gcc/f/lex.c.jj Wed Mar 21 14:19:51 2001 +++ gcc/f/lex.c Wed Mar 21 14:31:33 2001 @@ -1412,6 +1412,12 @@ ffelex_hash_ (FILE *finput) input_filename = old_input_filename; fatal ("Use `#line ...' instead of `# ...' in first line"); } + if (c == '\n' || c == EOF) + { + if (token != NULL && !ffelex_kludge_flag_) + ffelex_token_kill (token); + return c; + } } else error ("invalid #-line"); --- gcc/testsuite/g77.f-torture/compile/20010321-1.f.jj Wed Mar 21 14:34:40 2001 +++ gcc/testsuite/g77.f-torture/compile/20010321-1.f Wed Mar 21 14:35:18 2001 @@ -0,0 +1,8 @@ +# 1 "20010321-1.f" + SUBROUTINE TWOEXP +# 1 "include/implicit.h" 1 3 + IMPLICIT DOUBLE PRECISION (A-H) +# 3 "20010321-1.f" 2 3 + LOGICAL ANTI + ANTI = .FALSE. + END