|
|
|
|
|
by ultimaweapon
414 days ago
|
|
Checked addition by default will have too much overhead and it will hurt performance, which unacceptable in Rust since it was designed as a system language. Swift can use checked add by default since it was designed for application software. Your example code is not because it is faster to write, it is because it is impossible for its to overflow on that line. |
|
Or just because on Intel CPUs it has overhead, we must forget about writing safer code?