From: Douglas Gregor (gregod_at_[hidden])
Date: 2002-08-05 09:24:28
On Monday 05 August 2002 10:06 am, Richard Hadsell wrote:
> Actually, "whatever" says a lot. Or is that too trendy?
That's quite trendy :)
> global namespace, because I don't want to write "if (x == boost::whatever)"
> all the time.
I'm getting the distinct feeling we need a syntax change. The condition in
if (x ==boost::whatever)
will always return false in a boolean context, because x == boost::whatever
results in the unnameable 3rd state, which evaluates false in a boolean
context. Perhaps we should just disallow that syntax.
For the record, to check against the 3rd state, use
> If you don't want to leave it to users to create their own appropriate
> typedefs or #defines for the third state, how about making the name of the
> third state a template parameter? Then a single typedef could define the
> user's favorite names for both the tristate type and the third state.
How would you pass the name as a template parameter?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk