Blog post: Rust, a unique perspective


Rust: A unique perspective is my attempt to explain Rust’s memory safety guarantees in terms of unique versus shared access to memory.

These aren’t new ideas, but I couldn’t find much existing documentation that introduces them to beginning and intermediate Rust programmers, so I wrote my own.

Struct having a reference to a value in one of its variables
Why `Option<&T>` will cause "temporary value dropped while borrowed"?

I would make one small change, in the shared mutability section. I would reorder single-threaded shared mutability with multi-threaded shared mutability. Other than that minor nit, I love this article! I came across this idea earlier in a rather hidden blog (I don’t remember the name of the blog, if I do remember I will update this with a link), and since then I have been meaning to create a blog about it, but this blog did a fantastic job of covering the topic, far better than I would have done!

1 Like