pub enum Symbol {
N(String, SymbolAttribute, Option<UserDefinedTypeName>),
T(Terminal),
S(ScannerIndex),
Push(ScannerIndex),
Pop,
}
Expand description
A grammar symbol with different specificities
Variants§
N(String, SymbolAttribute, Option<UserDefinedTypeName>)
Non-terminal symbol, Meta symbol of the grammar.
T(Terminal)
Terminal symbol of the grammar.
S(ScannerIndex)
Instruction to switch scanner state
Push(ScannerIndex)
Instruction to push the index of the current scanner and switch to a scanner configuration with the given index
Pop
Instruction to pop the index of the scanner pushed before and switch to the scanner configuration with that index
Implementations§
Trait Implementations§
source§impl Ord for Symbol
impl Ord for Symbol
source§impl PartialOrd for Symbol
impl PartialOrd for Symbol
impl Eq for Symbol
impl StructuralPartialEq for Symbol
Auto Trait Implementations§
impl Freeze for Symbol
impl RefUnwindSafe for Symbol
impl Send for Symbol
impl Sync for Symbol
impl Unpin for Symbol
impl UnwindSafe for Symbol
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§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<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.