C is a portable Assembly Language. An optimizer changing its meaning is broken.
You mean twos complement, and it doesn't, but twos complement is not relevant here. All that's relevant is that it's undefined.
-
-
Ideal implementations are equivalent to gcc's (maybe-broken?) -ftrapv, i.e. catching overflows to reduce serious bugs down to DoS.
-
FWIW: I think ideally things should both define signed types as twos complement, and also maybe support explicit trap&saturate for types...
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.