pub struct FunctionId(/* private fields */);Expand description
A Function ID.
Implementations§
Source§impl FunctionId
impl FunctionId
Sourcepub const MAX: FunctionId
pub const MAX: FunctionId
The maximum index value.
Sourcepub const fn new(value: u32) -> FunctionId
pub const fn new(value: u32) -> FunctionId
Sourcepub const unsafe fn new_unchecked(value: u32) -> FunctionId
pub const unsafe fn new_unchecked(value: u32) -> FunctionId
Creates a new FunctionId from the given value.
§Safety
The caller must ensure that value is less than or equal to MAX.
Sourcepub const fn try_new(value: u32) -> Option<FunctionId>
pub const fn try_new(value: u32) -> Option<FunctionId>
Creates a new FunctionId from the given value.
Returns None if value exceeds MAX.
Sourcepub const fn from_usize(value: usize) -> FunctionId
pub const fn from_usize(value: usize) -> FunctionId
Sourcepub const unsafe fn from_usize_unchecked(value: usize) -> FunctionId
pub const unsafe fn from_usize_unchecked(value: usize) -> FunctionId
Creates a new FunctionId from the given value.
§Safety
The caller must ensure that value is less than or equal to MAX.
Sourcepub const fn try_from_usize(value: usize) -> Option<FunctionId>
pub const fn try_from_usize(value: usize) -> Option<FunctionId>
Creates a new FunctionId from the given value.
Returns None if value exceeds MAX.
Trait Implementations§
Source§impl Clone for FunctionId
impl Clone for FunctionId
Source§fn clone(&self) -> FunctionId
fn clone(&self) -> FunctionId
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FunctionId
impl Debug for FunctionId
Source§impl From<FunctionId> for ItemId
impl From<FunctionId> for ItemId
Source§fn from(value: FunctionId) -> ItemId
fn from(value: FunctionId) -> ItemId
Converts to this type from the input type.
Source§impl Hash for FunctionId
impl Hash for FunctionId
Source§impl Idx for FunctionId
impl Idx for FunctionId
Source§fn from_usize(value: usize) -> FunctionId
fn from_usize(value: usize) -> FunctionId
Construct an Index from a usize. This is equivalent to
From<usize>. Read moreSource§impl Ord for FunctionId
impl Ord for FunctionId
Source§fn cmp(&self, other: &FunctionId) -> Ordering
fn cmp(&self, other: &FunctionId) -> Ordering
1.21.0 · 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 PartialEq for FunctionId
impl PartialEq for FunctionId
Source§impl PartialOrd for FunctionId
impl PartialOrd for FunctionId
impl Copy for FunctionId
impl Eq for FunctionId
impl StructuralPartialEq for FunctionId
Auto Trait Implementations§
impl Freeze for FunctionId
impl RefUnwindSafe for FunctionId
impl Send for FunctionId
impl Sync for FunctionId
impl Unpin for FunctionId
impl UnwindSafe for FunctionId
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