Upgrade to Pro — share decks privately, control downloads, hide ads and more …

A Tale of Teaching Rust

A Tale of Teaching Rust

Andrew Lilley Brinker

April 10, 2025
Tweet

More Decks by Andrew Lilley Brinker

Other Decks in Programming

Transcript

  1. Zero-cost abstractions Move semantics Guaranteed memory safety (without GC) Threads

    without data races Trait-based generics Type inference Minimal runtime Optional unsafety And more!
  2. Zero-cost abstractions Move semantics Guaranteed memory safety (without GC) Threads

    without data races Trait-based generics Type inference Minimal runtime Optional unsafety And more!
  3. All data has an owner Ownership can be moved Old

    owner can’t use data Simple types can be copied
  4. Concurrency: Multiple threads of control Parallelism: Multiple threads of control,

    running at once Deadlock: All threads are stopped (dead) Livelock: Threads are live, but not progressing Data race: Non-syncing mutable data across threads Race condition: Result depends on execution order And so on…
  5. Unsafe blocks + unsafe trait impls: Tell the compiler “I’ve

    checked these!” The compiler assumes you did so correctly
  6. Can Rust be taught in 3 weeks? Not quite, but

    you can get students excited for more!