Boost logo

Boost :

Subject: Re: [boost] [optional] operator<(optional<T>, T) -- is it wrong?
From: Matt Calabrese (rivorus_at_[hidden])
Date: 2014-12-02 21:33:13


On Tue, Dec 2, 2014 at 1:46 PM, Matt Calabrese <rivorus_at_[hidden]> wrote:

>
>> However, when it specifies what the operators should do, that
> specification is in terms of std::lexicographical_compare, using the
> default ordering (std::less). These two specifications do not match as
> std::less and operator< do not necessarily relate (they differ with respect
> to certain fundamental types and library components, not to mention that
> they can differ in user code). Either the requirements or the
> implementation are incorrectly specified.
>

My mistake, I was wrong here -- lexicographical_compare does use < by
default and not std::less.

-- 
-Matt Calabrese

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