Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2003-08-31 14:46:03

David Abrahams wrote:
> "Peter Dimov" <pdimov_at_[hidden]> writes:
>> If you want a second opinion, I'm in the "just provide operator== and
>> operator<" camp.
> But, IIUC, if operator< is not provided, you'd oppose a std::less
> specialization, right?

Right. When there is one and only one strict weak ordering (equality) for a
type, not using operator< and operator== because some users might have
different expectations is misguided. It is pretty clear what set<variant> or
find(first, last, v) is supposed to do; variant_less or variant_equal is
"required boilerplate" as Howard says. :-)

Boost list run by bdawes at, gregod at, cpdaniel at, john at