ConstructableToken

Trait ConstructableToken 

Source
pub trait ConstructableToken {
    // Required method
    fn from_tokenizer(
        t: &Tokenizer<'_>,
        token_type: TokenType,
        index: usize,
        length: usize,
    ) -> Self;
}
Expand description

A token that can be produced by a Tokenizer.

Required Methods§

Source

fn from_tokenizer( t: &Tokenizer<'_>, token_type: TokenType, index: usize, length: usize, ) -> Self

Creates a token type from the given information.

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§