pub struct AutoExpiringPreemptDisabler { /* private fields */ }Expand description
RAII guard that sets a timeslice extension for its scope.
This guard is !Send and !Sync because timeslice extensions modify CPU- and thread-local
state.
Implementations§
Source§impl AutoExpiringPreemptDisabler
impl AutoExpiringPreemptDisabler
Sourcepub fn new(duration: DurationMono) -> Self
pub fn new(duration: DurationMono) -> Self
Creates a new guard and attempts to set a timeslice extension for duration.
Trait Implementations§
Source§impl Drop for AutoExpiringPreemptDisabler
impl Drop for AutoExpiringPreemptDisabler
Auto Trait Implementations§
impl !Send for AutoExpiringPreemptDisabler
impl !Sync for AutoExpiringPreemptDisabler
impl Freeze for AutoExpiringPreemptDisabler
impl RefUnwindSafe for AutoExpiringPreemptDisabler
impl Unpin for AutoExpiringPreemptDisabler
impl UnsafeUnpin for AutoExpiringPreemptDisabler
impl UnwindSafe for AutoExpiringPreemptDisabler
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T, U> Into<U> for Twhere
U: From<T>,
impl<T, U> Into<U> for Twhere
U: From<T>,
Source§impl<T> PinInit<T> for T
impl<T> PinInit<T> for T
Source§unsafe fn __pinned_init(self, slot: *mut T) -> Result<(), Infallible>
unsafe fn __pinned_init(self, slot: *mut T) -> Result<(), Infallible>
Initializes
slot. Read moreSource§fn pin_chain<F>(self, f: F) -> ChainPinInit<Self, F, T, E>where
F: FnOnce(Pin<&mut T>) -> Result<(), E>,
fn pin_chain<F>(self, f: F) -> ChainPinInit<Self, F, T, E>where
F: FnOnce(Pin<&mut T>) -> Result<(), E>,
First initializes the value using
self then calls the function f with the initialized
value. Read more