|
Boost Users : |
Subject: Re: [Boost-users] [context] How to set stack pointer in a platform-independent way?
From: Bjorn Reese (breese_at_[hidden])
Date: 2014-09-21 06:43:18
On 09/21/2014 07:06 AM, TONGARI J wrote:
> 2014-09-21 1:48 GMT+08:00 Nat Goodspeed <nat_at_[hidden]
> <mailto:nat_at_[hidden]>>:
> Doesn't the standard say pointer comparisons are only defined between
> pointers into the same container? Therefore wouldn't the above be UB?
>
>
> o_O!? That would be scary, do you really mean pointer or iterator?
> Where's the paragraph?
Paragraph [expr.rel]/3 does not specify this general case. Think of
near pointers in the segmented memory model.
For an in-depth discussion see commentary 1209 in:
http://c0x.coding-guidelines.com/6.5.8.pdf
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net