Skip to main content

ZeroableOption

Trait ZeroableOption 

Source
pub unsafe trait ZeroableOption { }
Expand description

Marker trait for types that allow Option<Self> to be set to all zeroes in order to write None to that location.

§Safety

The implementer needs to ensure that unsafe impl Zeroable for Option<Self> {} is sound.

Implementations on Foreign Types§

Source§

impl ZeroableOption for NonZeroI8

Source§

impl ZeroableOption for NonZeroI16

Source§

impl ZeroableOption for NonZeroI32

Source§

impl ZeroableOption for NonZeroI64

Source§

impl ZeroableOption for NonZeroI128

Source§

impl ZeroableOption for NonZeroIsize

Source§

impl ZeroableOption for NonZeroU8

Source§

impl ZeroableOption for NonZeroU16

Source§

impl ZeroableOption for NonZeroU32

Source§

impl ZeroableOption for NonZeroU64

Source§

impl ZeroableOption for NonZeroU128

Source§

impl ZeroableOption for NonZeroUsize

Source§

impl<T> ZeroableOption for &T

Source§

impl<T> ZeroableOption for &mut T

Source§

impl<T> ZeroableOption for Box<T>

Source§

impl<T> ZeroableOption for NonNull<T>

Source§

impl<T, U> ZeroableOption for fn(U₁, U₂, …, Uₙ) -> T

Implemented for function pointers with up to 20 arity.

Source§

impl<T, U> ZeroableOption for extern "C" fn(U₁, U₂, …, Uₙ) -> T

Implemented for function pointers with up to 20 arity.

Source§

impl<T, U> ZeroableOption for unsafe fn(U₁, U₂, …, Uₙ) -> T

Implemented for function pointers with up to 20 arity.

Source§

impl<T, U> ZeroableOption for unsafe extern "C" fn(U₁, U₂, …, Uₙ) -> T

Implemented for function pointers with up to 20 arity.

Implementors§