pub trait Matcher<K> {
// Required method
fn try_match(
&self,
first_char: char,
input: &mut BufferedInput<'_>,
) -> MatchResult<K>;
}
Expand description
A matcher fn matches a character (and and any following characters) and returns a T
to indicate the kind of token (see Token
)
input
is always fresh (i.e. its buffer is empty)