pub(crate) enum RawRepr {
Show 18 variants
Transparent,
C,
Rust,
U8,
U16,
U32,
U64,
U128,
Usize,
I8,
I16,
I32,
I64,
I128,
Isize,
Align(NonZeroU32),
PackedN(NonZeroU32),
Packed,
}Expand description
The result of parsing a single #[repr(...)] attribute or a single
directive inside a compound #[repr(..., ...)] attribute.
Variants§
Transparent
C
Rust
U8
U16
U32
U64
U128
Usize
I8
I16
I32
I64
I128
Isize
Align(NonZeroU32)
PackedN(NonZeroU32)
Packed
Implementations§
Trait Implementations§
Source§impl<Pcked: With<NonZeroU32>> TryFrom<RawRepr> for AlignRepr<Pcked>
impl<Pcked: With<NonZeroU32>> TryFrom<RawRepr> for AlignRepr<Pcked>
Source§type Error = FromRawReprError<UnsupportedReprError>
type Error = FromRawReprError<UnsupportedReprError>
The type returned in the event of a conversion error.
Source§fn try_from(
raw: RawRepr,
) -> Result<AlignRepr<Pcked>, FromRawReprError<UnsupportedReprError>>
fn try_from( raw: RawRepr, ) -> Result<AlignRepr<Pcked>, FromRawReprError<UnsupportedReprError>>
Performs the conversion.
Source§impl<Prim: With<PrimitiveRepr>> TryFrom<RawRepr> for CompoundRepr<Prim>
impl<Prim: With<PrimitiveRepr>> TryFrom<RawRepr> for CompoundRepr<Prim>
Source§type Error = FromRawReprError<UnsupportedReprError>
type Error = FromRawReprError<UnsupportedReprError>
The type returned in the event of a conversion error.
Source§fn try_from(
raw: RawRepr,
) -> Result<CompoundRepr<Prim>, FromRawReprError<UnsupportedReprError>>
fn try_from( raw: RawRepr, ) -> Result<CompoundRepr<Prim>, FromRawReprError<UnsupportedReprError>>
Performs the conversion.
impl Copy for RawRepr
impl Eq for RawRepr
impl StructuralPartialEq for RawRepr
Auto Trait Implementations§
impl Freeze for RawRepr
impl RefUnwindSafe for RawRepr
impl Send for RawRepr
impl Sync for RawRepr
impl Unpin for RawRepr
impl UnwindSafe for RawRepr
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