OptionInitSomeFn

Type Alias OptionInitSomeFn 

Source
pub type OptionInitSomeFn = unsafe fn(option: PtrUninit, value: PtrConst) -> PtrMut;
Expand description

Initialize an option with Some(value)

§Safety

The option parameter must point to uninitialized memory of sufficient size. The function must properly initialize the memory. value is moved out of (with core::ptr::read) — it should be deallocated afterwards (e.g. with core::mem::forget) but NOT dropped.