3 ms·
If you ran valgrind (and mudflap) then any error that might be detected by a compiler with range checking will be detected. Any further errors will not be fixe
by ars 12y ago
If you ran valgrind (and mudflap) then any error that might be detected by a compiler with range checking will be detected.
Any further errors will not be fixed by any supposed "safe" language either.
Imagining that another language will make a difference is a mistake. It will not.
- pjmlp 12y agoAssuming such tools exist for a specific OS, and not only UNIX flavours.
- dllthomas 12y agoStrictly, "... or that you can run your tests on an OS that does, and your code does not behave meaningfully differently between OSes." Either way, it may or may not be a strong assumption, depending on domain...
- dllthomas 12y ago"If you ran valgrind (and mudflap) then any error that might be detected by a compiler with range checking will be detected." Only if you can be sure you have touched all the interesting portions of input-space. Ideally your tests are doing this, but wherever your tests miss aren't covered by valgrind or mudflap but are covered by a change of language. That's a part of what's meant by safe. It's not that it's impossible to write correct code in an unsafe language. It's that it's difficult to impossible to verify that you have written correct code. I'm very willing to include available tools in that calculation, but valgrind and mudflap (while tremendously useful) cannot give guarantees.