[ub] Justification for < not being a total order on pointers?
Lawrence Crowl
Lawrence at Crowl.org
Mon Oct 28 06:11:14 CET 2013
On 10/16/13, Stephan T. Lavavej <stl at exchange.microsoft.com> wrote:
> Yep - I intended for less<void> to simply be op< in functor form, with no
> additional semantics.
>
> Separately, I believe that the Core Language should simply recognize the
> fact that all machines these days have a flat memory model.
I think this would be a mistake. Capability-based machines are more
secure, and security is growing in importance. It is not clear to me that
we can assume that *all* pointers will be totally ordered. I think we can
assume that all pointers from a single allocation domain are totally ordered.
(This would mean, for instance, that you could compare two pointers from
the primary heap, but you could not compare a heap pointer with a stack
pointer.
> (Two's complement and 8-bit bytes would be nice too.)
We already have two's complement in the intN_t types.
Asking for 8-bit bytes seems a bit harder.
--
Lawrence Crowl
More information about the ub
mailing list