pub struct InstId(/* private fields */);Expand description
A unique identifier for an instruction in the MIR.
Implementations§
Source§impl InstId
impl InstId
Sourcepub const CHECKS_MAX_INDEX: bool = true
pub const CHECKS_MAX_INDEX: bool = true
Whether this index type performs bounds checking.
Sourcepub fn from_foreign<F>(value: F) -> InstIdwhere
F: Idx,
pub fn from_foreign<F>(value: F) -> InstIdwhere
F: Idx,
Convert an index from another index type.
Sourcepub const unsafe fn from_usize_unchecked(value: usize) -> InstId
pub const unsafe fn from_usize_unchecked(value: usize) -> InstId
Create an index from a usize without bounds checking.
§SAFETY
The caller must ensure value < (u32::MAX as usize).
Sourcepub const unsafe fn from_raw_unchecked(raw: u32) -> InstId
pub const unsafe fn from_raw_unchecked(raw: u32) -> InstId
Create an index from a raw u32 without bounds checking.
§SAFETY
The caller must ensure the value is not u32::MAX.
Sourcepub const fn from_usize(value: usize) -> InstId
pub const fn from_usize(value: usize) -> InstId
Trait Implementations§
Source§impl AddAssign for InstId
impl AddAssign for InstId
Source§fn add_assign(&mut self, other: InstId)
fn add_assign(&mut self, other: InstId)
Performs the
+= operation. Read moreSource§impl AddAssign<usize> for InstId
impl AddAssign<usize> for InstId
Source§fn add_assign(&mut self, other: usize)
fn add_assign(&mut self, other: usize)
Performs the
+= operation. Read moreimpl Copy for InstId
impl Eq for InstId
Source§impl Idx for InstId
impl Idx for InstId
Source§impl Ord for InstId
impl Ord for InstId
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for InstId
impl PartialOrd for InstId
Source§impl PartialOrd<usize> for InstId
impl PartialOrd<usize> for InstId
impl StructuralPartialEq for InstId
Auto Trait Implementations§
impl Freeze for InstId
impl RefUnwindSafe for InstId
impl Send for InstId
impl Sync for InstId
impl Unpin for InstId
impl UnsafeUnpin for InstId
impl UnwindSafe for InstId
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T, R> CollectAndApply<T, R> for T
impl<T, R> CollectAndApply<T, R> for T
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
fn equivalent(&self, key: &K) -> bool
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<I, T> IdxSliceIndex<I, T> for Iwhere
I: Idx,
impl<I, T> IdxSliceIndex<I, T> for Iwhere
I: Idx,
type Output = T
fn get( self, slice: &IndexSlice<I, [T]>, ) -> Option<&<I as IdxSliceIndex<I, T>>::Output>
fn get_mut( self, slice: &mut IndexSlice<I, [T]>, ) -> Option<&mut <I as IdxSliceIndex<I, T>>::Output>
fn index( self, slice: &IndexSlice<I, [T]>, ) -> &<I as IdxSliceIndex<I, T>>::Output
fn index_mut( self, slice: &mut IndexSlice<I, [T]>, ) -> &mut <I as IdxSliceIndex<I, T>>::Output
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more