Boost logo

Boost :

Subject: Re: [boost] review request: addition to type_traits libraryofis_less_comparable<T, U> and others
From: David Abrahams (dave_at_[hidden])
Date: 2009-12-07 12:49:49


On Dec 7, 2009, at 2:34 AM, John Maddock wrote:

>>> Where R is the expected return type. In all but a vanishingly small number
>>> of cases R will be bool. If you really want to support the "don't care"
>>> case for a return type, use has_operator_less<T, dont_care> where
>>> "dont_care" is a special placeholder type that you define (could use a
>>> better name though?).
>>
>> the "don't care" case was a strong requirement from previous discussion.
>> I like your proposed solution has_operator_less<T, U, dont_care>
>>
>> dont_care would have to be an empty class maybe boost::type_traits::dont_care?
>
> Yep.

Why not void?

--
David Abrahams
BoostPro Computing
http://boostpro.com

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