[][src]Struct sunrise_libuser::zero_box::ZeroBox

#[repr(transparent)]pub struct ZeroBox<T> {
    owned_box: Box<T>,
}

A wrapper around a Box that can initialize itself directly on the heap.

Fields

owned_box: Box<T>

The box we secretely wrap.

Implementations

impl<T> ZeroBox<T>[src]

pub fn new(x: T) -> ZeroBox<T>[src]

Regular Box initialisation.

pub fn new_zeroed() -> ZeroBox<T> where
    T: ZeroInitialized
[src]

Allocate a ZeroBox directly on the heap, and zero it.

This function does not cause any stack-to-heap copy.

Trait Implementations

impl<T> AsMut<T> for ZeroBox<T>[src]

impl<T> AsRef<T> for ZeroBox<T>[src]

impl<T: Debug> Debug for ZeroBox<T>[src]

impl<T> Deref for ZeroBox<T>[src]

type Target = T

The resulting type after dereferencing.

impl<T> DerefMut for ZeroBox<T>[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for ZeroBox<T> where
    T: RefUnwindSafe

impl<T> Send for ZeroBox<T> where
    T: Send

impl<T> Sync for ZeroBox<T> where
    T: Sync

impl<T> Unpin for ZeroBox<T>

impl<T> UnwindSafe for ZeroBox<T> where
    T: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SizedIPCBuffer for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.