by simfoo · 11y ago · 0 comments
I'm a professional C++ programmer for a decade and have started to look into Rust, and there's no way that C++ is easier to reason about.
There's no automatic copying of complex data in Rust, you can't move something away and later use it again, you can't invalidate interators and this list goes on and on.
At the beginning you have to get used to the borrow system of Rust, learn the idioms, but after that, it really seems to be in a lot of parts a better C++.
Yes you are, and the only reason for that is that Rust's system is checked by the compiler, C++ is not.
It's really easy to screw up with C++, forgetting to make something noncopyable and then causing double free or use after free issues.