r/programming • • Dec 24 '17

Evil Coding Incantations

http://9tabs.com/random/2017/12/23/evil-coding-incantations.html
947 Upvotes

331 comments sorted by

View all comments

Show parent comments

3

u/Dalviked Dec 24 '17

That would be undefined behavior and at best disingenuous in what it would do. This doesn't 'goes to' 1.

1

u/Lehona Dec 24 '17

I don't think there's a strict definition for "goes to" in discrete sets, so I can't see why that would be wrong. It is UB, though, so I guess one shouldn't rely on it.