Traits now support async fn
and -> impl Trait
(with some limitations), the compiler got faster, version =
in Cargo.toml is now optional, and many small functions have been stabilized!
Traits now support async fn
and -> impl Trait
(with some limitations), the compiler got faster, version =
in Cargo.toml is now optional, and many small functions have been stabilized!
Honestly the only things that are similar to C++ are small amounts of C-like syntax, RAII, smart pointers, and iterators. And even so, Rust improves those features a lot. The list of things that Rust rejects from C++ is much larger; Rust does not have:
new
anddelete
(perhaps discouraged in modern C++)Result
values)Rust does OOP very differently and leans harder into functional paradigms.
You could argue that C++'s new is Rust’s Box::new, and delete is replaced by RAII. Same concepts but way better ergonomy.