Boost logo

Boost :

From: Eric Niebler (eric_at_[hidden])
Date: 2007-04-29 13:26:18


Larry Evans wrote:
> On 04/27/2007 03:25 PM, Eric Niebler wrote:
>> Larry Evans wrote:
>>
>>> why not
>>> do the following renames:
>>>
>>> proto::_ -> proto::true_
>>>
>>> proto::not_<_> -> proto::false_
>>>
>>> ?
>>
>> No, proto::_ is a placeholder. And proto::not_<> can logically negate
>> any grammar, not just proto::_.
>>
> Actaully, the following is what I had in mind:
>
> namespace boost
> {
> namespace proto
> {
> struct
> true_
> : _
> {};
> struct
> false_
> : not_<true_>
> {};
>
> }}//exit boost::proto namespace
>
> Why? Because I think (I haven't tested it) the same
> laws for mpl::bool_ and it's associated operations:
>
> mpl::not_
> mpl::and_
> mpl::or_
>
> would apply to proto's true_, false_, not_,....

I guess I don't see how these types would be used. In what contexts
would using proto::true_ make more sense than using proto::_ ?

-- 
Eric Niebler
Boost Consulting
www.boost-consulting.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk