pub struct MaybeBox<T> { /* private fields */ }Expand description
Box-like type providing opportunistic heap allocation when the alloc feature is available
that falls back to stack allocation when it’s unavailable.
Implementations§
Trait Implementations§
Source§impl<T: PartialEq> PartialEq for MaybeBox<T>
impl<T: PartialEq> PartialEq for MaybeBox<T>
impl<T> StructuralPartialEq for MaybeBox<T>
Auto Trait Implementations§
impl<T> Freeze for MaybeBox<T>
impl<T> RefUnwindSafe for MaybeBox<T>where
T: RefUnwindSafe,
impl<T> Send for MaybeBox<T>where
T: Send,
impl<T> Sync for MaybeBox<T>where
T: Sync,
impl<T> Unpin for MaybeBox<T>
impl<T> UnsafeUnpin for MaybeBox<T>
impl<T> UnwindSafe for MaybeBox<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more