This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/34695] New: Preprocessor warning->error conversion from -Werror is silent
- From: "ed at catmur dot co dot uk" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 6 Jan 2008 22:14:43 -0000
- Subject: [Bug preprocessor/34695] New: Preprocessor warning->error conversion from -Werror is silent
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
When -Werror is passed in, libcpp silently converts warnings to errors:
$ gcc foo.c -Wall -Werror
foo.c:3:1: error: "FOO" redefined
foo.c:2:1: error: this is the location of the previous definition
This is potentially confusing, and inconsistent with cc, which displays:
$ gcc foo.c -Wall -Werror
cc1: warnings being treated as errors
foo.c:1: warning: return type defaults to ‘int’
foo.c: In function ‘main’:
foo.c:1: warning: control reaches end of non-void function
--
Summary: Preprocessor warning->error conversion from -Werror is
silent
Product: gcc
Version: 4.2.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: preprocessor
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ed at catmur dot co dot uk
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34695