|
Boost : |
From: Jeremy Siek (jsiek_at_[hidden])
Date: 2000-11-29 15:51:41
Instead of "are clearly legal", did you really mean "should clearly be
legal"?
The current wording of the standard in 25.1.2 does not explicitly talk
about mixed comparisons, it just has T models EqualityComparable.
On Wed, 29 Nov 2000, Matthew Austern wrote:
> Jeremy Siek wrote:
> >
> > The issue of two types involved in a comparison also seems to apply to the
> > family of std::find functions, but with EqualityComparable instead of
> > LessThanComparable.
>
> Except there I think there is no question: mixed comparisons
> are clearly legal. The reason they're problematic for
> lower_bound is that the comparison that's used for searching
> must be the same as the comparison that was used for sorting
> the sequence.
>
> What's at issue here, for lower_bound, is whether it can ever
> make sense to say that two comparison functions are the
> same even though one is a comparison between T and T and the
> other is a comparison between T and U. There is no such
> issue for find.
>
> --Matt
>
>
>
>
----------------------------------------------------------------------
Jeremy Siek www: http://www.lsc.nd.edu/~jsiek/
Ph.D. Candidate email: jsiek_at_[hidden]
Univ. of Notre Dame work phone: (219) 631-3906
----------------------------------------------------------------------
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk