Enum NodeKind
#[non_exhaustive]pub enum NodeKind<'a> {
Tree {
data: &'a str,
},
Token(&'a Token),
None,
Foreign(&'a ForeignValue),
}Expand description
What a Cursor points at. Provisional: the deferred
visitor classes build on this, so #[non_exhaustive].
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Tree
A rule node; data is its resolved display name.
Token(&'a Token)
A leaf token.
None
A maybe_placeholders hole (Lark’s None child).
Foreign(&'a ForeignValue)
A transform-produced opaque host value.
Trait Implementations§
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for NodeKind<'a>
impl<'a> !UnwindSafe for NodeKind<'a>
impl<'a> Freeze for NodeKind<'a>
impl<'a> Send for NodeKind<'a>
impl<'a> Sync for NodeKind<'a>
impl<'a> Unpin for NodeKind<'a>
impl<'a> UnsafeUnpin for NodeKind<'a>
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