Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
0x10c0fe11ce
on Nov 30, 2013
|
parent
|
context
|
favorite
| on:
A glimpse of undefined behavior in C
I just ran this after compiling it with clang-500.2.79 based on LLVM 3.3svn, and the output was 140. Maybe GCC is to blame?
hbar
on Nov 30, 2013
|
next
[–]
It's undefined in the spec. So GCC and clang are both correct.
steveklabnik
on Nov 30, 2013
|
prev
[–]
It's undefined behaviour, so you won't get a consistent answer.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: