#[repr(u32)]pub enum State {
SomeStateX = 0,
SomeStateY = 1,
}
Expand description
Due to some limitations on how attribute macro currently work, our proc macro needs to be placed on an inner module. This means that other code using us has to have an unnecessary level of indirection to use the types/ functions in that module, so instead we just re-export everything so they only need to access the single top level module to get everything
Variants§
Trait Implementations§
Source§impl CheckedBitPattern for State
impl CheckedBitPattern for State
Source§type Bits = u32
type Bits = u32
Self
must have the same layout as the specified Bits
except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern
.Source§fn is_valid_bit_pattern(bits: &Self::Bits) -> bool
fn is_valid_bit_pattern(bits: &Self::Bits) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self
.Source§impl TryFromPrimitive for State
impl TryFromPrimitive for State
impl Copy for State
impl NoUninit for State
Auto Trait Implementations§
impl Freeze for State
impl RefUnwindSafe for State
impl Send for State
impl Sync for State
impl Unpin for State
impl UnwindSafe for State
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