This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug other/36901] pedwarn() + -pedantic-errors + -w (inhibit_warnings) should not emit errors
- From: "eric dot weddington at atmel dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Aug 2008 19:34:43 -0000
- Subject: [Bug other/36901] pedwarn() + -pedantic-errors + -w (inhibit_warnings) should not emit errors
- References: <bug-36901-13511@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #9 from eric dot weddington at atmel dot com 2008-08-09 19:34 -------
You're right in that limits.h for the AVR does not use #include_next. The
limits.h that the AVR toolchain uses is installed by gcc.
Unfortunately your suggestion makes the situation worse. There are now 4
failures instead of one:
FAIL: gcc.dg/pr36901-1.c (test for excess errors)
FAIL: gcc.dg/pr36901-4.c overflow (test for warnings, line )
FAIL: gcc.dg/pr36901-4.c overflow (test for errors, line )
FAIL: gcc.dg/pr36901-4.c (test for excess errors)
Here are the details from the log:
Executing on host: /usr/local/avrdev/gcc/build/gcc/xgcc
-B/usr/local/avrdev/gcc/build/gcc/
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c -pedantic-errors
-DSTACK_SIZE=2048 -DNO_TRAMPOLINES -fno-show-column -S -DSIGNAL_SUPPRESS
-mmcu=atmega128 -o pr36901-1.s (timeout = 300)
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
pr36901.h: No such file or directory
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c: In function 'foo':
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: 'sc'
undeclared (first use in this function)
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: (Each
undeclared identifier is reported only once
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: for each
function it appears in.)
compiler exited with status 1
output is:
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
pr36901.h: No such file or directory
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c: In function 'foo':
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: 'sc'
undeclared (first use in this function)
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: (Each
undeclared identifier is reported only once
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: for each
function it appears in.)
FAIL: gcc.dg/pr36901-1.c (test for excess errors)
Excess errors:
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
pr36901.h: No such file or directory
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: 'sc'
undeclared (first use in this function)
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: (Each
undeclared identifier is reported only once
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-1.c:6: error: for each
function it appears in.)
Executing on host: /usr/local/avrdev/gcc/build/gcc/xgcc
-B/usr/local/avrdev/gcc/build/gcc/
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-2.c -pedantic-errors
-w -DSTACK_SIZE=2048 -DNO_TRAMPOLINES -fno-show-column -S -DSIGNAL_SUPPRESS
-mmcu=atmega128 -o pr36901-2.s (timeout = 300)
PASS: gcc.dg/pr36901-2.c (test for excess errors)
Executing on host: /usr/local/avrdev/gcc/build/gcc/xgcc
-B/usr/local/avrdev/gcc/build/gcc/
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-3.c -pedantic-errors
-DSTACK_SIZE=2048 -DNO_TRAMPOLINES -fno-show-column -S -DSIGNAL_SUPPRESS
-mmcu=atmega128 -o pr36901-3.s (timeout = 300)
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-3.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901.h:2: warning: integer
overflow in expression
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901.h:2: error: overflow in
constant expression
compiler exited with status 1
output is:
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-3.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901.h:2: warning: integer
overflow in expression
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901.h:2: error: overflow in
constant expression
PASS: gcc.dg/pr36901-3.c In file included (test for warnings, line )
PASS: gcc.dg/pr36901-3.c overflow (test for warnings, line )
PASS: gcc.dg/pr36901-3.c overflow (test for errors, line )
PASS: gcc.dg/pr36901-3.c (test for excess errors)
Executing on host: /usr/local/avrdev/gcc/build/gcc/xgcc
-B/usr/local/avrdev/gcc/build/gcc/
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c -pedantic-errors
-Wsystem-headers -DSTACK_SIZE=2048 -DNO_TRAMPOLINES -fno-show-column -S
-DSIGNAL_SUPPRESS -mmcu=atmega128 -o pr36901-4.s (timeout = 300)
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
#include_next is a GCC extension
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
pr36901.h: No such file or directory
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c: In function 'foo':
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: 'sc'
undeclared (first use in this function)
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: (Each
undeclared identifier is reported only once
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: for each
function it appears in.)
compiler exited with status 1
output is:
In file included from
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:3:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
#include_next is a GCC extension
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
pr36901.h: No such file or directory
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c: In function 'foo':
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: 'sc'
undeclared (first use in this function)
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: (Each
undeclared identifier is reported only once
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: for each
function it appears in.)
PASS: gcc.dg/pr36901-4.c In file included (test for warnings, line )
FAIL: gcc.dg/pr36901-4.c overflow (test for warnings, line )
FAIL: gcc.dg/pr36901-4.c overflow (test for errors, line )
PASS: gcc.dg/pr36901-4.c #include_next (test for errors, line )
FAIL: gcc.dg/pr36901-4.c (test for excess errors)
Excess errors:
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-system.h:2: error:
pr36901.h: No such file or directory
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: 'sc'
undeclared (first use in this function)
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: (Each
undeclared identifier is reported only once
/usr/local/avrdev/gcc/gcc/gcc/testsuite/gcc.dg/pr36901-4.c:6: error: for each
function it appears in.)
--
eric dot weddington at atmel dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2008-08-09 19:34:42
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36901