pub enum Node {
Alt {
branches: Vec<NodeId>,
},
Concat {
items: Vec<NodeId>,
},
Repeat {
repeat: Repeat,
body: NodeId,
span: Ignored<Span>,
},
Optional {
body: NodeId,
},
RuleRef {
name: RuleName,
span: Ignored<Span>,
},
CharVal(CharVal),
NumVal {
value: NumVal,
span: Ignored<Span>,
},
ProseVal(String),
}Expand description
Variants§
Alt
a / b / c.
Fields
Concat
a b c.
Repeat
2*5a.
Fields
Optional
[a], modeled as a / empty for coverage purposes.
RuleRef
A reference to another rule, resolved via the side table.
Fields
CharVal(CharVal)
A quoted string terminal.
NumVal
A numeric terminal.
ProseVal(String)
<prose>.
Trait Implementations§
impl Eq for Node
impl StructuralPartialEq for Node
Auto Trait Implementations§
impl Freeze for Node
impl RefUnwindSafe for Node
impl Send for Node
impl Sync for Node
impl Unpin for Node
impl UnsafeUnpin for Node
impl UnwindSafe for Node
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