gear idea
Possible Rust

Learning what’s possible in Rust.
Jump to Navigation

Page 2 of 2


Enum or Trait Object

Rust has two major mechanisms for delegating logic: enums and trait objects, and it may be unclear when to use one or the other. In this post, I will walk through how each works, what the tradeoffs are, and how to choose the right option for your code.

Jul 27th, 2020 · Guide · #enums, #trait objects

Rust Lints You May Not Know

The Rust compiler ships with a number of useful lints on by default, and many use Clippy to provide additional lints. It’s less well known that the Rust compiler ships with some useful lints which are set to allow by default, meaning they don’t generate warnings. In this post, I’ll explain what each of these lints does, and why it might be useful.

Jun 21st, 2020 · Pattern · #lints