[ub] Justification for < not being a total order on pointers?
Gabriel Dos Reis
gdr at microsoft.com
Wed Oct 16 17:06:00 CEST 2013
| -----Original Message-----
| From: ub-bounces at open-std.org [mailto:ub-bounces at open-std.org] On Behalf
| Of Nevin Liber
| Sent: Wednesday, October 16, 2013 7:54 AM
| To: WG21 UB study group
| Subject: Re: [ub] Justification for < not being a total order on pointers?
|
| On 15 October 2013 18:10, Gabriel Dos Reis <gdr at microsoft.com
| <mailto:gdr at microsoft.com> > wrote:
|
|
| I would not have trouble telling people (especially notices): "Ignore expect
| talks
| about operator< on pointers. Prefer std::less<T>, unless you meant a
| relationship
| between objects pointed to, in which use operator<. Mean what you say
| and say
| what you mean."
|
|
|
| So what about std::less<void>? Should people be using it?
What is wrong about it?
| This is not a
| theoretical question, as there are committee members who recommend it over
| std::less<T>, and book authors might start doing it as well.
-- Gaby
More information about the ub
mailing list