This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/25314] [3.4/4.0/4.1/4.2 Regression] Unreachable code at beginning of switch statement is not reported anymore
- From: "Uwe dot Seimet at seimet dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Dec 2005 06:21:33 -0000
- Subject: [Bug c/25314] [3.4/4.0/4.1/4.2 Regression] Unreachable code at beginning of switch statement is not reported anymore
- References: <bug-25314-7407@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #6 from Uwe dot Seimet at seimet dot de 2005-12-12 06:21 -------
Subject: Re: [3.4/4.0/4.1/4.2 Regression] Unreachable code at beginning of
switch statement is not reported anymore
Hello,
Another comment from my side: When using -Wunreachable-code as a means
to detect unreachable code in a switch statement I noticed that, just like
the manpage says, -Wunreachable-code issues a lot of warnings when compiling
with -g. There are so many warnings with "-g -Wunreachable-code" that it is
impossible to see which warning is justified and which is not.
The behavior with old versions of gcc was much more transparent. With gcc
3.3 I got an accurate warning for the unreachable code in the code sample I
sent you. Which gcc 4.0 I only get this warning with -Wunreachable-code,
but there are so many other (not useful) warnings that -Wunreachable-code
is not a good solution wrt the switch statement.
Best regards, Uwe
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25314