Hacker News new | ask | show | jobs
by Rusky 3045 days ago
For what it's worth, you can still compile your code to panic on overflow in release builds today if that's worth it for your use case.
1 comments

Yes, that's exactly the path I would choose. Not that I'm the target audience in my present day job but nothing is more irritating than having a production environment that subtly differs from the test environment at the language level.
I think it's more frustrating when production fails more often than the test environment than the other way around but I see your point. Main thing to consider obviously is that enabling the checks in the release code will degrade performance. Ultimately, overflow is a difficult problem to solve, I don't think there's a universal win that doesn't trade something off.
its fairly common to have a compiler produce different builds for release vs debug envs.