Comment by xigoi
1 day ago
Are there any languages other than C and C++ that have this “nasal demons” interpretation of undefined behavior?
1 day ago
Are there any languages other than C and C++ that have this “nasal demons” interpretation of undefined behavior?
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.
Are you asking if there are programming languages in which how undefined behaviour behaves is strictly defined?
I think so, at least when it comes to assuming that multi-threading data races don't happen.
Rust and Zig do, and I think also Go.