Trait lang_util::node::NodeContent[][src]

pub trait NodeContent: Debug + Clone + PartialEq + Sized {
    fn into_node<T>(self) -> Node<T>
    where
        T: From<Self> + NodeContent
, { ... }
fn spanned(self, start: LexerPosition, end: LexerPosition) -> Node<Self> { ... } }

Trait for AST node contents.

All nodes which will be stored in a Node need to implement this.

Provided methods

fn into_node<T>(self) -> Node<T> where
    T: From<Self> + NodeContent
[src]

Convert the contents into a node

fn spanned(self, start: LexerPosition, end: LexerPosition) -> Node<Self>[src]

Add span information to a syntax node

Loading content...

Implementations on Foreign Types

impl NodeContent for &'static str[src]

Loading content...

Implementors

Loading content...