pub struct SlotId { /* private fields */ }Implementations§
Source§impl SlotId
impl SlotId
pub const INVALID: Self
pub const TAG_BITS: u32 = 8u32
pub const TAG_MASK: u32 = 255u32
pub const STATE_BITS: u32 = 2u32
pub const STATE_MASK: u32 = 768u32
pub const OCCUPIED_TAG: u32 = 256u32
pub const fn new(index: u32, generation: u32) -> Self
Sourcepub const unsafe fn new_unchecked(index: u32, generation: u32) -> Self
pub const unsafe fn new_unchecked(index: u32, generation: u32) -> Self
§Safety
generation, when masked out with STATE_MASK, must equal OCCUPIED_TAG.
pub const fn index(self) -> u32
pub const fn generation(self) -> u32
pub const fn tag(self) -> u32
Trait Implementations§
Source§impl Ord for SlotId
impl Ord for SlotId
Source§impl PartialOrd for SlotId
impl PartialOrd for SlotId
impl Copy for SlotId
impl Eq for SlotId
Auto Trait Implementations§
impl Freeze for SlotId
impl RefUnwindSafe for SlotId
impl Send for SlotId
impl Sync for SlotId
impl Unpin for SlotId
impl UnwindSafe for SlotId
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