Enum spirt::qptr::layout::Components
source · pub(super) enum Components {
Scalar,
Elements {
stride: NonZeroU32,
elem: Rc<MemTypeLayout>,
fixed_len: Option<NonZeroU32>,
},
Fields {
offsets: SmallVec<[u32; 4]>,
layouts: SmallVec<[Rc<MemTypeLayout>; 4]>,
},
}
Variants§
Implementations§
source§impl Components
impl Components
sourcepub(super) fn find_components_containing(
&self,
offset_range: Range<u32>
) -> impl Iterator<Item = usize> + '_
pub(super) fn find_components_containing( &self, offset_range: Range<u32> ) -> impl Iterator<Item = usize> + '_
Return all components (by index), which completely contain offset_range
.
If offset_range
is zero-sized (offset_range.start == offset_range.end
),
this can return multiple components, with at most one ever being non-ZST.
Auto Trait Implementations§
impl RefUnwindSafe for Components
impl !Send for Components
impl !Sync for Components
impl Unpin for Components
impl UnwindSafe for Components
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