pub enum Origin<'s> {
HeapAllocated,
Borrowed {
parent: Option<&'s Partial<'s>>,
init_mark: InitMark<'s>,
},
}
Expand description
Origin of the partial — did we allocate it? Or is it borrowed?
Variants§
HeapAllocated
It was allocated via alloc::alloc
and needs to be deallocated on drop,
moving out, etc.
Borrowed
It was generously lent to us by some outside code, and we are NOT to free it (although we should still uninitialize any fields that we initialized).
Auto Trait Implementations§
impl<'s> Freeze for Origin<'s>
impl<'s> RefUnwindSafe for Origin<'s>
impl<'s> !Send for Origin<'s>
impl<'s> !Sync for Origin<'s>
impl<'s> Unpin for Origin<'s>
impl<'s> !UnwindSafe for Origin<'s>
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