Skip to content

Glossary: Rust in Practice

undefined behavior

Also written: UB

What happens when unsafe code breaks a rule the compiler relies on: the program may crash, give wrong answers or seem fine until it doesn't.

Where the book teaches it

Related terms

unsafeMiri