pub struct Bin<'a> { /* private fields */ }
Expand description
A container that holds values for later destruction.
It is automatically cleared when it is dropped.
Implementations§
Source§impl<'a> Bin<'a>
impl<'a> Bin<'a>
Sourcepub fn add<T: Send + 'a>(&self, value: T)
pub fn add<T: Send + 'a>(&self, value: T)
Add a value to the bin.
This may drop the value immediately, but will attempt to store it so that it can be dropped later.
Trait Implementations§
Auto Trait Implementations§
impl<'a> !Freeze for Bin<'a>
impl<'a> !RefUnwindSafe for Bin<'a>
impl<'a> Send for Bin<'a>
impl<'a> Sync for Bin<'a>
impl<'a> Unpin for Bin<'a>
impl<'a> !UnwindSafe for Bin<'a>
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