Trait AtomicAdd

Source
pub unsafe trait AtomicAdd<Rhs = Self>: AtomicType {
    // Required method
    fn rhs_into_delta(rhs: Rhs) -> <Self::Repr as AtomicImpl>::Delta;
}
Expand description

Types that support atomic add operations.

§Safety

wrapping_add any value of type Self::Repr::Delta obtained by Self::rhs_into_delta() to any value of type Self::Repr obtained through transmuting a value of type Self to must yield a value with a bit pattern also valid for Self.

Required Methods§

Source

fn rhs_into_delta(rhs: Rhs) -> <Self::Repr as AtomicImpl>::Delta

Converts Rhs into the Delta type of the atomic implementation.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl AtomicAdd for i32

Source§

impl AtomicAdd for i64

Source§

impl AtomicAdd for isize

Source§

impl AtomicAdd for u32

Source§

impl AtomicAdd for u64

Source§

impl AtomicAdd for usize

Implementors§