Comment

Comment by ajross

I'll just say it: that's a clang bug. The assumption being made by the optimizer is wrong, for exactly the reason that overflow exists.

I get very tired of people trying to make this "really" about "undefined behavior" sanity when real compilers are real software with real behavior. And here there is a clearly desired behavior (whether or not it got written into a standard somehwere), and clang implemented something else. That's wrong.

parent ajross 8 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton