Get the latest tech news
Rust's Sneaky Deadlock With `if let` Blocks
Rust is my favorite programming language. I've been writing Rust for about 6 years, from college to professionally, and I'm vocal about how helpful the compi...
I've been writing Rust for about 6 years, from college to professionally, and I'm vocal about how helpful the compiler is in catching particularly nasty multithreaded issues and memory bugs. Generally, this is fine, and you can sus out if a program is going to cause a deadlock by just making sure you aren't acquiring multiple simultaneous locks. I wrote this block because this has specifically bitten different Rust crates in the wasmCloud project multiple times (most recently and I hoped to prevent the same mistake for others.
Or read this on Hacker News