News for hackers. Stuff that matters.
Re:C++ needs undefined behavior, but maybe less by olliej on Friday November 24, 2023 @02:32PM (#38407315)
Yeah a lot of the badness of UB in C and C++ is stupid and has no place in the language. UB should be reserved for cases where there is no definable outcome, and everything else should be unspecified or implementation defined. Things like overflow, null sereferences, etc should not give the compiler the opportunity to go back in time and remove preceding branches (which is what the current interpretation of UB allows).

There are no comments on this comment yet.