Unsafe Rust demystified

Florian Gilcher

⏱ 1-day-workshop
beginner
intermediate
10:00-18:00, Monday, 15th June 2026

Unsafe is one of the most debated features of the Rust language. Sadly though, it's also often the most misunderstood.

In this talk, I will build an intuition for how Rust handles unsafety, how to work with the feature and how to safely interact with it.

To make the talk accessible to Rust beginners and practitioners alike, we will start with definitions and then discuss a number of clear examples that go from simple to complex.

We will cover unsafe both from a writing and from a review perspective.

There's no need to fear the unsafe - you just need to be careful and well-equipped around it!

Outline

In my training experience, I find that the biggest problem of Rust unsafe features is that people don't actually know more than the word and a vague feeling of insecurity.

We will cover the following topics: * Unsafe is a superset of the safe Rust language * Use cases: when to reach for unsafe and when to avoid it * Unsafe functions vs. unsafe blocks - preconditions vs promises * The core/std unsafe API * The scope of unsafety * Encapsulating unsafety in safe Rust * Pointers vs references - when to reach for what.


🏷 rust
🏷 unsafe

Florian Gilcher

Florian Gilcher has been around Rust for more then a decade. From 2015-2021, Florian was part of the Rust project and Rust foundation leadership.

Nowadays, Florians main concern is bringing Rust into safety-critical systems, together with his company, Ferrous Systems.