* cpplib.c (do_line): Pedwarn for #line > 32767.
authorAlexandre Oliva <oliva@lsd.ic.unicamp.br>
Wed, 16 Feb 2000 08:43:57 +0000 (08:43 +0000)
committerAlexandre Oliva <aoliva@gcc.gnu.org>
Wed, 16 Feb 2000 08:43:57 +0000 (08:43 +0000)
From-SVN: r32006

gcc/ChangeLog
gcc/cpplib.c

index 67e454bed512ebdfe7435cf1cea5228b22e0ec71..7db972f075c3ebda186dea4e8134238b3728640b 100644 (file)
@@ -1,5 +1,7 @@
 2000-02-16  Alexandre Oliva  <oliva@lsd.ic.unicamp.br>
 
+       * cpplib.c (do_line): Pedwarn for #line > 32767.
+
        * c-lex.c (readescape): Warn about '\x', but do not reject it.
 
 2000-02-15  Jonathan Larmour  <jlarmour@redhat.co.uk>
index 844b89fda65a52f597a57abab6ea8dae4d5ad202..9ffa4a1cedf37831d1e587957aad2e716ca2007a 100644 (file)
@@ -1346,7 +1346,7 @@ do_line (pfile, keyword)
     }      
   CPP_SET_WRITTEN (pfile, old_written);
 
-  if (CPP_PEDANTIC (pfile) && new_lineno <= 0)
+  if (CPP_PEDANTIC (pfile) && (new_lineno <= 0 || new_lineno > 32767))
     cpp_pedwarn (pfile, "line number out of range in `#line' command");
 
   token = get_directive_token (pfile);