pub struct SlabClaim { /* private fields */ }Expand description
A reserved slab slot for the async runtime.
Call .spawn(future) to write a task and enqueue it, or drop to
return the slot to the freelist. Nothing is lost on drop — the
future was never constructed.
Lifetime-free — safe because the runtime owns the slab for the
duration of block_on, and SlabClaim can only be created inside
block_on.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SlabClaim
impl RefUnwindSafe for SlabClaim
impl !Send for SlabClaim
impl !Sync for SlabClaim
impl Unpin for SlabClaim
impl UnsafeUnpin for SlabClaim
impl UnwindSafe for SlabClaim
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