pub enum AtomicClass {
Bool,
Int {
bytes: u64,
signed: bool,
},
Float {
bytes: u64,
},
Ptr,
}Expand description
What kind of Rust atomic an object is reached through.
The width comes from the C type’s size, so long is an AtomicI64 on an
LP64 target and an AtomicI32 on an ILP32 one; the
data-model check is what makes that assumption safe.
Variants§
Bool
_Bool, which is AtomicBool — a Rust bool may only ever hold 0 or
1, so it may not be reached through an integer atomic.
Int
An integer (or enum) of bytes bytes: AtomicI8 … AtomicU64.
Float
float or double, reached through the integer atomic of the same
width and to_bits/from_bits.
Ptr
An object pointer, which is AtomicPtr.
Implementations§
Trait Implementations§
Source§impl Clone for AtomicClass
impl Clone for AtomicClass
impl Copy for AtomicClass
Source§impl Debug for AtomicClass
impl Debug for AtomicClass
impl Eq for AtomicClass
Source§impl PartialEq for AtomicClass
impl PartialEq for AtomicClass
impl StructuralPartialEq for AtomicClass
Auto Trait Implementations§
impl Freeze for AtomicClass
impl RefUnwindSafe for AtomicClass
impl Send for AtomicClass
impl Sync for AtomicClass
impl Unpin for AtomicClass
impl UnsafeUnpin for AtomicClass
impl UnwindSafe for AtomicClass
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