Skip to main content

SingleTokenPattern

Trait SingleTokenPattern 

Source
pub trait SingleTokenPattern: LSend {
    // Required method
    fn matches_token(&self, token: &Token, source: &[char]) -> bool;
}
Expand description

A simpler version of the Pattern trait that only matches a single token.

Required Methods§

Source

fn matches_token(&self, token: &Token, source: &[char]) -> bool

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§