logoalt Hacker News

xigoitoday at 11:02 AM4 repliesview on HN

Are there any languages other than C and C++ that have this “nasal demons” interpretation of undefined behavior?


Replies

josephgtoday at 11:57 AM

I assume this is a product of sufficiently advanced compilers. Other LLVM languages almost certainly suffer from this too, including Zig, Swift and unsafe rust.

bregmatoday at 1:23 PM

Are you asking if there are programming languages in which how undefined behaviour behaves is strictly defined?

FartyMcFartertoday at 11:17 AM

I think so, at least when it comes to assuming that multi-threading data races don't happen.

IshKebabtoday at 1:28 PM

Rust and Zig do, and I think also Go.