Trait cmark_syntax::Highlight[][src]

pub trait Highlight: Sized + for<'a> Logos<'a, Source = str> {
    const LANG: &'static str;
    const START: Self;

    fn kind(tokens: &[Self; 2]) -> Kind;
}
Expand description

A type of token that can be highlighted.

Associated Constants

Name of the language of this highlighter.

The token denoting the start, before input.

Required methods

Determine the kind of a token from the current and the previous token.

Implementors