CustomNode

Trait CustomNode 

Source
pub trait CustomNode: ParseRecoverable + ToTokens {
    // Required method
    fn peek_element(input: ParseStream<'_>) -> bool;
}

Required Methods§

Source

fn peek_element(input: ParseStream<'_>) -> bool

Peeks the token stream to decide whether this node should be parsed.

Recieves a ParseStream::fork.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§