On 12/26/2017 3:59 PM, codephantom wrote:
On Tuesday, 26 December 2017 at 22:55:18 UTC, Walter Bright wrote:
I compiled the code snippet with clang++, a modern C++ compiler, with -Wall. It did not detect the obvious error.
https://clang.llvm.org/docs/AddressSanitizer.html


That's not mechanical checking, because it is a runtime check that requires a test case that would actually trip it. Without a careful, manually created test suite, it does not detect anything. AS is not present in the shipped product.

AS is a hackish workaround for the failure of the language to prevent such 
things.

AS is just a more modern valgrind, which has been around for ages, and has failed to turn C/C++ into memory safe languages.

Reply via email to