pub struct VariantLayout<FieldIdx: Idx> {
pub size: Size,
pub backend_repr: BackendRepr,
pub field_offsets: IndexVec<FieldIdx, Size>,
/* private fields */
}Fields§
§size: Size§backend_repr: BackendRepr§field_offsets: IndexVec<FieldIdx, Size>Implementations§
Source§impl<FieldIdx: Idx> VariantLayout<FieldIdx>
impl<FieldIdx: Idx> VariantLayout<FieldIdx>
pub fn from_layout(layout: LayoutData<FieldIdx, impl Idx>) -> Self
pub fn is_uninhabited(&self) -> bool
pub fn has_fields(&self) -> bool
Trait Implementations§
Source§impl<FieldIdx: Clone + Idx> Clone for VariantLayout<FieldIdx>
impl<FieldIdx: Clone + Idx> Clone for VariantLayout<FieldIdx>
Source§fn clone(&self) -> VariantLayout<FieldIdx>
fn clone(&self) -> VariantLayout<FieldIdx>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<FieldIdx: Eq + Idx> Eq for VariantLayout<FieldIdx>
Source§impl<FieldIdx: PartialEq + Idx> PartialEq for VariantLayout<FieldIdx>
impl<FieldIdx: PartialEq + Idx> PartialEq for VariantLayout<FieldIdx>
Source§fn eq(&self, other: &VariantLayout<FieldIdx>) -> bool
fn eq(&self, other: &VariantLayout<FieldIdx>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<FieldIdx: PartialEq + Idx> StructuralPartialEq for VariantLayout<FieldIdx>
Auto Trait Implementations§
impl<FieldIdx> Freeze for VariantLayout<FieldIdx>
impl<FieldIdx> RefUnwindSafe for VariantLayout<FieldIdx>where
FieldIdx: RefUnwindSafe,
impl<FieldIdx> Send for VariantLayout<FieldIdx>where
FieldIdx: Send,
impl<FieldIdx> Sync for VariantLayout<FieldIdx>where
FieldIdx: Sync,
impl<FieldIdx> Unpin for VariantLayout<FieldIdx>where
FieldIdx: Unpin,
impl<FieldIdx> UnsafeUnpin for VariantLayout<FieldIdx>
impl<FieldIdx> UnwindSafe for VariantLayout<FieldIdx>where
FieldIdx: UnwindSafe,
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