Struct arithmetic_eval::exec::IndexedId
source · pub struct IndexedId {
pub prefix: &'static str,
pub index: usize,
}
Expand description
Indexed module ID containing a prefix part (e.g., snippet
).
The ID is Display
ed as {prefix} #{index + 1}
:
let module_id = IndexedId::new("snippet", 4);
assert_eq!(module_id.to_string(), "snippet #5");
Fields§
§prefix: &'static str
Prefix that can identify the nature of the module, such as snippet
.
index: usize
0-based index of the module.
Implementations§
Trait Implementations§
source§impl PartialEq for IndexedId
impl PartialEq for IndexedId
impl Copy for IndexedId
impl Eq for IndexedId
impl ModuleId for IndexedId
impl StructuralPartialEq for IndexedId
Auto Trait Implementations§
impl Freeze for IndexedId
impl RefUnwindSafe for IndexedId
impl Send for IndexedId
impl Sync for IndexedId
impl Unpin for IndexedId
impl UnwindSafe for IndexedId
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: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more