pub unsafe auto trait Freeze { }๐ฌThis is a nightly-only experimental API. (
freeze #121675)Expand description
Used to determine whether a type contains
any UnsafeCell internally, but not through an indirection.
This affects, for example, whether a static of that type is
placed in read-only static memory or writable static memory.
This can be used to declare that a constant with a generic type
will not contain interior mutability, and subsequently allow
placing the constant behind references.
ยงSafety
This trait is a core part of the language, it is just expressed as a trait in libcore for convenience. Do not implement it for other types.
Implementorsยง
impl<T> Freeze for NonZero<T>where
    T: ZeroablePrimitive + Freeze,
Available on non-crate feature 
ferrocene_certified only.impl<T: PointeeSized> !Freeze for UnsafeCell<T>
Available on non-crate feature 
ferrocene_certified only.impl<T: PointeeSized> Freeze for *const T
impl<T: PointeeSized> Freeze for *const T is TyPat { hir_id: HirId(DefId(0:10795 ~ core[01a9]::pat::{impl#4}).12), kind: NotNull, span: library/core/src/pat.rs:89:67: 89:72 (#0) }
Available on non-crate feature 
ferrocene_certified only.impl<T: PointeeSized> Freeze for *mut T
impl<T: PointeeSized> Freeze for *mut T is TyPat { hir_id: HirId(DefId(0:10797 ~ core[01a9]::pat::{impl#5}).12), kind: NotNull, span: library/core/src/pat.rs:91:65: 91:70 (#0) }
Available on non-crate feature 
ferrocene_certified only.