3 ms·
The link is an outdated version r0, this is r2 (don't know if it's the latest) http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p0907r2.html http://www.o
by lloda 8y ago
The link is an outdated version r0, this is r2 (don't know if it's the latest) http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p0907r2.html http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p090...
- jwilk 8y agoThe main change between [P0907r0] and the subsequent revision is to maintain undefined behavior when signed integer overflow occurs, instead of defining wrapping behavior.
- slededit 8y agoAnd the joy I originally had is once again lost.
- deleted 8y ago[deleted]
- badsectoracula 8y agoGah, what is the point then?
- sanxiyn 8y agoThe point is that signed integers are two's complement. After all, it is the title.
- barrkel 8y agoNaive overflow checks are often done by adding two positive numbers together and checking if the result is negative. If wrapping is undefined, this no longer works, and the overflow check may be eliminated.
- danra 8y agoYou can always get the most up-to-date public version using wg21.link/pxxxx. So for this proposal: https://wg21.link/p0907 https://wg21.link/p0907