aboutsummaryrefslogtreecommitdiff
path: root/gcc/cpperror.c
diff options
context:
space:
mode:
authorNeil Booth <neil@daikokuya.demon.co.uk>2001-04-08 10:01:18 +0000
committerNeil Booth <neil@gcc.gnu.org>2001-04-08 10:01:18 +0000
commit2f878973cdb605f01778a5bbd67f7459db14b7ff (patch)
tree1f4ac5b16223e9ffcc027d3568d6d791ee3a30c7 /gcc/cpperror.c
parente542e61832a106a11a0aab3f366d2ba0a3f4ad41 (diff)
downloadgcc-2f878973cdb605f01778a5bbd67f7459db14b7ff.zip
gcc-2f878973cdb605f01778a5bbd67f7459db14b7ff.tar.gz
gcc-2f878973cdb605f01778a5bbd67f7459db14b7ff.tar.bz2
cpperror.c (print_location): Don't special case <stdin>.
* cpperror.c (print_location): Don't special case <stdin>. (_cpp_begin_message): Handle WARNING_SYSHDR the same as WARNING, but we don't check if we're in system headers. * cpplib.h (enum error_type): WARNING_SYSHDR: New. * cpplib.c (do_warning): Warn in system headers. From-SVN: r41186
Diffstat (limited to 'gcc/cpperror.c')
-rw-r--r--gcc/cpperror.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/cpperror.c b/gcc/cpperror.c
index 50bd907..60af7b5 100644
--- a/gcc/cpperror.c
+++ b/gcc/cpperror.c
@@ -124,8 +124,6 @@ print_location (pfile, filename, pos)
if (filename == 0)
filename = buffer->nominal_fname;
- if (*filename == '\0')
- filename = _("<stdin>");
if (line == 0)
fprintf (stderr, "%s: ", filename);
@@ -159,6 +157,7 @@ _cpp_begin_message (pfile, code, file, pos)
if (CPP_IN_SYSTEM_HEADER (pfile)
&& ! CPP_OPTION (pfile, warn_system_headers))
return 0;
+ case WARNING_SYSHDR:
if (CPP_OPTION (pfile, warnings_are_errors)
|| (code == PEDWARN && CPP_OPTION (pfile, pedantic_errors)))
{