What are the most common Rust constructs that are essential to every Rust programmer. The stuff that gets used in most typical Rust programs.
The Rust book goes through all the really essential constructs.
There are small useful things like
Option.as_ref(), and a bunch of other helper methods on
You’ll find combo of
Arc<Mutex<T>> used often, especially if you’re implementing a design pattern (like linked lists) from another language that’s more relaxed about references and mutability.
I’m collecting them here: https://octodon.social/@rust?max_id=99049070528284281
There’s an in-progress list of Rust Patterns you might find useful! Similar, but slightly different are:
- Rust by Example, a collection of examples for the purpose of learning Rust
- the Rust Cookbook that organizes examples by the task you want to accomplish
- API guidelines, most relevant if you’re writing a library rather than an application
Hope those help!