News for hackers. Stuff that matters.
Re:Don’t assume that safety comes for free: a Swift case study by kibwen on Tuesday December 06, 2016 @07:23PM (#13119478)

  > Being able to explicitly disable the check when you know 
  > what you want is the right balance, whether it's &+ in 
  > Swift or (better, imo) .wrapping_add() in Rust.
To clarify, Rust does disable the overflow check in release mode (and the benchmarks shown in this post are exactly why, to much heated debate), wrapping instead. `.wrapping_add()` in Rust is just what you use in order to guarantee wrapping behavior in debug mode as well (and also to guard against future changes to the language specification, which currently allows implementations to choose to either panic or wrap on overflow). In order to get the behavior of Swift's basic `+` in Rust, you'd use `.checked_add().unwrap()`.
Re:Don’t assume that safety comes for free: a Swift case study by arcticbull on Tuesday December 06, 2016 @08:28PM (#13119803)
Of course, you're right -- which is a behavior I'm even more in favor of, wherein your debug builds fail fast all the time but your release builds don't.