aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Stallman <rms@gnu.org>1993-02-09 18:50:33 +0000
committerRichard Stallman <rms@gnu.org>1993-02-09 18:50:33 +0000
commit5105ecec4cf8d713c17e9c4c9aad48084760ec29 (patch)
treeb52177c332434938c9754574d3499c5f7c59660d /gcc
parentb5e9dd0342da5d6d632f94cd9acd7277a9f75414 (diff)
downloadgcc-5105ecec4cf8d713c17e9c4c9aad48084760ec29.zip
gcc-5105ecec4cf8d713c17e9c4c9aad48084760ec29.tar.gz
gcc-5105ecec4cf8d713c17e9c4c9aad48084760ec29.tar.bz2
(main): Fix lineno of "does not end in newline" message.
(finclude): Likewise. From-SVN: r3447
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cccp.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/cccp.c b/gcc/cccp.c
index d5ffdaa..564fb56 100644
--- a/gcc/cccp.c
+++ b/gcc/cccp.c
@@ -1856,6 +1856,9 @@ main (argc, argv)
rescan (&outbuf, 0);
+ if (missing_newline)
+ fp->lineno--;
+
if (pedantic && missing_newline)
pedwarn ("file does not end in newline");
@@ -4215,6 +4218,9 @@ finclude (f, fname, op, system_header_p, dirptr)
output_line_command (fp, op, 0, enter_file);
rescan (op, 0);
+ if (missing_newline)
+ fp->lineno--;
+
if (pedantic && missing_newline)
pedwarn ("file does not end in newline");