pub struct SymbolId { /* private fields */ }Expand description
A unique, owned symbol key: the hierarchical path (for display and ordering) plus the chain of member indices from the root down to the symbol (for uniqueness).
Implementations§
Source§impl SymbolId
impl SymbolId
Sourcepub fn synthetic(path: &str) -> SymbolId
pub fn synthetic(path: &str) -> SymbolId
A key that names no real symbol, for unit tests of code that only needs keys to
compare (it equals no key SymbolUid::uid produces).
Sourcepub fn synthetic_tagged(tag: &str) -> SymbolId
pub fn synthetic_tagged(tag: &str) -> SymbolId
A key that names no symbol, for a value the simulator itself keeps in a
symbol-keyed table (a procedural assertion’s const'(expr) capture,
vj-codegen::sva::proc). It never equals a real symbol’s key: the
member chain is the impossible [u32::MAX].
Sourcepub fn derive(&self, tag: &str) -> SymbolId
pub fn derive(&self, tag: &str) -> SymbolId
A key for storage the simulator itself adds next to this symbol (a
sampled-value history cell, crate::sva::sampled): this symbol’s
path plus ${tag}, with the same member chain. Two symbols never
collide (their chains differ), nor do one symbol’s distinct tags
(their paths differ); a derived key equals a real symbol’s only if
that symbol is this one and is literally named {name}${tag}.
Sourcepub fn key_string(&self) -> String
pub fn key_string(&self) -> String
The path and member chain as one string: a unique, deterministic
text form, for building a Self::derive tag from another symbol.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for SymbolId
impl<'de> Deserialize<'de> for SymbolId
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for SymbolId
Source§impl Ord for SymbolId
impl Ord for SymbolId
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialOrd for SymbolId
impl PartialOrd for SymbolId
impl StructuralPartialEq for SymbolId
Auto Trait Implementations§
impl Freeze for SymbolId
impl RefUnwindSafe for SymbolId
impl Send for SymbolId
impl Sync for SymbolId
impl Unpin for SymbolId
impl UnsafeUnpin for SymbolId
impl UnwindSafe for SymbolId
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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
key and return true if they are equal.