Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The code can be unsafe because it is physically impossible to test for every input in a computer. This is where various engineering designs come in which reduce the area of testing based on some theories.

Also, even in math, there are enough mistakes in publications (not just typos, but reasoning errors) which hopefully do not affect the eventual results in any fundamental way. The equivalent of safe code in computer science would be equivalent of completely formal proofs in mathematics (like in Coq and similar languages), but probably much more difficult due to existence of temporal conditions.



Err there are other ways to prove (memory) safety than exhaustive testing, such as better type systems and static analysis (Rust) or better run time checks (any garbage collected language)


Memory safety is not the only type of safety though. There are race conditions for example.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: