3 ms·
> Look - can we just admit that most C++ apps don't have thousands of use-after-free errors? For sure! It's those one-every-million-lines-of-code ones that ar
by imron 4y ago
> Look - can we just admit that most C++ apps don't have thousands of use-after-free errors?
For sure! It's those one-every-million-lines-of-code ones that are the problem, and that slip through code review and rear their head only in production at odd hours of the day.
> this sort of thing is not going to convince anyone to use rust that doesn't want to already
My post was in reply to someone asking the question what does Rust give you over modern C++, and this was an example showing that modern C++ still has its holes.
I'm not a Rust absolutist, nor do I think everything should be written (or rewritten) in Rust, but the biggest thing going in its favour is that offloads the cognitive load of checking lifetimes and ownership to the compiler, and that turns whole classes of runtime bugs in to compile time bugs.