r[safety]

Unsafety

r[safety.intro] Unsafe operations are those that can potentially violate the memory-safety guarantees of Rust's static semantics.

r[safety.unsafe-ops] The following language level features cannot be used in the safe subset of Rust:

r[safety.unsafe-deref]

r[safety.unsafe-static]

r[safety.unsafe-union-access]

r[safety.unsafe-call]

r[safety.unsafe-target-feature-call]

r[safety.unsafe-impl]

r[safety.unsafe-extern]

r[safety.unsafe-attribute]

  1. Prior to the 2024 edition, extern blocks were allowed to be declared without unsafe.