3 ms·
Rust does not claim to prevent memory leaks.
by steveklabnik 3y ago
Rust does not claim to prevent memory leaks.
- wongarsu 3y agoIt is true that Rust considers memory leaks safe. But Rust's type system still helps compared to C. The two toy examples in the article wouldn't have happened in idiomatic Rust. Though the same can be said about C++, or any other language preferring RAII over explicit free calls.