aboutsummaryrefslogtreecommitdiff
path: root/libcpp/lex.c
diff options
context:
space:
mode:
authorDave Korn <dave.korn@artimi.com>2007-05-31 02:06:48 +0000
committerDave Korn <davek@gcc.gnu.org>2007-05-31 02:06:48 +0000
commited0e74e0a670f53ee3ea7e9ba58a70a3ce7e9d82 (patch)
tree501c91d22ae6c3724250991e91e46a26b7bc4ee7 /libcpp/lex.c
parent8af2fec40bfd6889ab47b47d0a9cfaa5102c2507 (diff)
downloadgcc-ed0e74e0a670f53ee3ea7e9ba58a70a3ce7e9d82.zip
gcc-ed0e74e0a670f53ee3ea7e9ba58a70a3ce7e9d82.tar.gz
gcc-ed0e74e0a670f53ee3ea7e9ba58a70a3ce7e9d82.tar.bz2
re PR preprocessor/14331 (please add option to suppress warning message "no newline at end of file")
2007-05-31 Dave Korn <dave.korn@artimi.com> PR preprocessor/14331 * lex.c (_cpp_get_fresh_line): Don't warn if no newline at EOF. From-SVN: r125212
Diffstat (limited to 'libcpp/lex.c')
-rw-r--r--libcpp/lex.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/libcpp/lex.c b/libcpp/lex.c
index 296b399..ef59f900 100644
--- a/libcpp/lex.c
+++ b/libcpp/lex.c
@@ -852,11 +852,8 @@ _cpp_get_fresh_line (cpp_reader *pfile)
&& buffer->next_line > buffer->rlimit
&& !buffer->from_stage3)
{
- /* Only warn once. */
+ /* Clip to buffer size. */
buffer->next_line = buffer->rlimit;
- cpp_error_with_line (pfile, CPP_DL_PEDWARN, pfile->line_table->highest_line,
- CPP_BUF_COLUMN (buffer, buffer->cur),
- "no newline at end of file");
}
return_at_eof = buffer->return_at_eof;