pub trait Token: Spanned + Sized {
    const PUNCT_KINDS: &'static [PunctKind];
    const NOT_FOLLOWED_BY: &'static [PunctKind];

    fn new(span: Span) -> Self;
    fn ident(&self) -> Ident;
}
Expand description

The type is a keyword.

Required Associated Constants

The sequence of punctuations that make up the token.

Punctuations that will not follow the token.

Required Methods

Creates the keyword from the given span.

Returns an identifier for this keyword.

Implementors