This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/52806] bogus "zero as null pointer constant" warning
- From: "paolo.carlini at oracle dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 31 Mar 2012 13:06:14 +0000
- Subject: [Bug c++/52806] bogus "zero as null pointer constant" warning
- Auto-submitted: auto-generated
- References: <bug-52806-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52806
--- Comment #2 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-03-31 13:06:14 UTC ---
And, hey, I don't really see what's the problem with not passing the -Wzero* at
all if you don't want the warning.
That can *always* be done, but if I once and for all prevent the -Wzero* from
doing anything useful (or even being rejeted) when the default -std=c++98 is in
effect, then, people who want to use it order to start removing explicit zeros
(like, in conditionals and in many other context where it can easily be done
without involving nullptr) don't have *any* help from the compiler.
All in all, my current opinion is that we don't want to do this.