------- Comment #2 from jg at jguk dot org 2010-02-14 12:34 -------
(In reply to comment #1) > (In reply to comment #0) > > Could the warning message below be revised to include a warning that NULL > > will > > evaluate to false or zero? > > What else would it evaluate to? In C++ NULL is defined as 0, or 0L. However, as it is a special keyword, I would like g++ to identify that it is special, and warn when initialising non pointer types to be NULL. > N.B. with recent versions of GCC -Wconversion is needed and the conversion to > bool no longer warns Ah ok, so it does this already, with the -Wconversion.. I had expected that would be in -Wall! Can it be added to -Wall? Jon -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31755