Rust Language Resources

Feel free to add anything!

General learning resources

A Rust course from Richard Feldman, known from his work in the Elm community.

A book about Rust also apparently referred to as “The Book” in the Rust community.

A youtube series going through the above book:

“The Rust Programming Language” by Steve Klabnik and Carol Nichols
https://doc.rust-lang.org/book/

Traits

dyn Trait and impl Trait can be new/confusing syntax and is fairly subtle:

Async

Understanding Async (Rust Futures) better by building an executor for them:
https://rust-lang.github.io/async-book/02_execution/04_executor.html

A post about from Tokio’s author about its executor:

Async recursion isn’t possible out-of-the-box. There exists a macro to help with that:
async_recursion package

By default async fns in traits are disallowed:
“why async fn in traits are hard”

Recursion

If you’re used to functional programming languages and used to creating recursive data structure & recursive functions for working with them, you might be surprised to hear that in Rust recursion is not discouraged.

Here’s a discussion about representing an AST and its functions in Rust in the help forum that may be helpful for people coming from e.g.Haskell:

Linked Lists

Linked lists in Rust are discouraged, just like recursion.
There’s fringe cases for when they’re useful, but it’s somewhat hard to do in rust.
This book goes over how that could work and teaches you a lot about different kinds of smart pointers in the process:

4 Likes

I’m partway through this course, which has been a great intro for someone new to the language:

2 Likes

I think this one is great because it breaks down the Rust Language Book which I find to be very useful.

1 Like

This looks like a fun rust book: Introduction - Learning Rust With Entirely Too Many Linked Lists

I’ll add it to the list above

1 Like

Almost forgot to share this amazing resource.

Once you start working with Rust, this cheat sheet is a nice refresher to have when you get stuck.
I find myself revisiting it for Rust ABI details. It also contains some PL theoretic information that will help you understand Rust better.