Nevin Liber <nevin@eviloverlord.com> writes:You're right. Historically, it came from segmented architectures.
| On 26 August 2013 11:00, Jeffrey Yasskin <jyasskin@google.com> wrote:
|
|
| Could someone explain why we need to allow operator<(T*) to be a non-order?
|
|
| It comes from C. I believe it comes from the days of segmented architectures.
However, because it has been in the standard for that long, some
implementations may have taken advantage of that semantics restriction
even if they are not targeting segmented architecture.
So, it is not
the case that because we don't have wide spread architecture anymore
means that removing that restriction is a breeze. It will invalidate
implementations that use compilation and program transformations based
on that.
If you make operator< a total order for all valid pointers (and
including the usual one-past-the-end pointers), I suspect you might also
as a by-product impose a stronger requirement on operator== on pointers.