3 ms·
>In Rust debug builds, integer overflows crash That's true with C/C++ compilers too, if you want, using UBSan.
by 1over137 4y ago
>In Rust debug builds, integer overflows crash
That's true with C/C++ compilers too, if you want, using UBSan.
- roca 4y agoUnsigned integer overflow is not undefined behavior in C++ so won't be caught by UBSan. Also, UBSan is more overhead than turning on Rust's overflow checking.