Boost logo

Boost Users :

From: Dave Steffen (dgsteffen_at_[hidden])
Date: 2008-01-02 20:06:43


On Wednesday 02 January 2008, Victor A. Wagner Jr. wrote:
> Robert Dailey wrote:
[...]

> I understand there are enough people who dislike if (foo) and
> if(!foo) that adding a "null" is going into c+0x I personally like
> the (foo) and (!foo) notation and think "needing" a "NULL" is
> pointless given the other holes in the language

  It's not just a case of notation, and I don't think that's why
  "nullptr" is going into the new standard. There are other problems the lack
  of a null pointer type creates. From the link I posted elsethread (
  http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2431.pdf ),
consider

 std::string s1( false ); // compiles, calls char* constructor with null
 std::string s2( true ); // error

 I'd say that "nullptr" is, rather, closing up one of those holes in
 the language.

  (OT: apologies for the long wordy legalese stuff in the sig in my
  earlier posting. Forgot to clean that up.)

-- 
Dave Steffen - Software Engineer 4
Numerica Corporation (www.numerica.us <http://www.numerica.us/> ) 

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net