Struct CompareExchangeError
pub struct CompareExchangeError<'g, T: ?Sized + Pointable, P: Pointer<T>> { pub current: Shared<'g, T>, pub new: P }
The error returned on failed compare-and-swap operation.
Fields
current: Shared<'g, T>The value in the atomic pointer at the time of the failed operation.
new: PThe new value, which the operation failed to store.
Trait Implementations
impl<T, P: Pointer<T> + Debug> Debug for CompareExchangeError<'_, T, P>
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Auto Trait Implementations
impl<'g, T, P> !Send for CompareExchangeError<'g, T, P>
impl<'g, T, P> !Sync for CompareExchangeError<'g, T, P>
impl<'g, T, P> Freeze for CompareExchangeError<'g, T, P>
where
Shared<'g, T>: Freeze,
P: Freeze,
T: ?Sized,
impl<'g, T, P> RefUnwindSafe for CompareExchangeError<'g, T, P>
where
Shared<'g, T>: RefUnwindSafe,
P: RefUnwindSafe,
T: ?Sized,
impl<'g, T, P> Unpin for CompareExchangeError<'g, T, P>
where
Shared<'g, T>: Unpin,
P: Unpin,
T: ?Sized,
impl<'g, T, P> UnsafeUnpin for CompareExchangeError<'g, T, P>
where
Shared<'g, T>: UnsafeUnpin,
P: UnsafeUnpin,
T: ?Sized,
impl<'g, T, P> UnwindSafe for CompareExchangeError<'g, T, P>
where
Shared<'g, T>: UnwindSafe,
P: UnwindSafe,
T: ?Sized,
Blanket Implementations
impl<T> Any for CompareExchangeError<'g, T, P>
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for CompareExchangeError<'g, T, P>
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for CompareExchangeError<'g, T, P>
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for CompareExchangeError<'g, T, P>
fn from(t: T) -> TReturns the argument unchanged.
impl<T> Pointable for CompareExchangeError<'g, T, P>
const ALIGN: usize = const ALIGN: usize = mem::align_of::<T>();;type Init = T;unsafe fn init(init: <T as Pointable>::Init) -> usizeunsafe fn deref<'a>(ptr: usize) -> &'a Tunsafe fn deref_mut<'a>(ptr: usize) -> &'a mut Tunsafe fn drop(ptr: usize)
impl<T, U> Into<U> for CompareExchangeError<'g, T, P>
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for CompareExchangeError<'g, T, P>
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for CompareExchangeError<'g, T, P>
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>