rustc_parse::parser

Module token_type

Source

Macros§

Structs§

  • Used by various Parser methods such as check_keyword and eat_keyword. The first field is always used by those methods. The second field is only used when the first field doesn’t match.
  • Used by various Parser methods such as check and eat. The first field is always by used those methods. The second field is only used when the first field doesn’t match.
  • A bitset type designed specifically for Parser::expected_token_types, which is very hot. u128 is the smallest integer that will fit every TokenType value.

Enums§

  • Used in “expected”/“expected one of” error messages. Tokens are added here as necessary. Tokens with values (e.g. literals, identifiers) are represented by a single variant (e.g. Literal, Ident).