UNPKG

638 BTypeScriptView Raw
1/**
2 * An exported enum describing the different kinds of tokens that the
3 * lexer emits.
4 */
5export const TokenKind: _TokenKind;
6
7type _TokenKind = {
8 SOF: '<SOF>';
9 EOF: '<EOF>';
10 BANG: '!';
11 DOLLAR: '$';
12 AMP: '&';
13 PAREN_L: '(';
14 PAREN_R: ')';
15 SPREAD: '...';
16 COLON: ':';
17 EQUALS: '=';
18 AT: '@';
19 BRACKET_L: '[';
20 BRACKET_R: ']';
21 BRACE_L: '{';
22 PIPE: '|';
23 BRACE_R: '}';
24 NAME: 'Name';
25 INT: 'Int';
26 FLOAT: 'Float';
27 STRING: 'String';
28 BLOCK_STRING: 'BlockString';
29 COMMENT: 'Comment';
30};
31
32/**
33 * The enum type representing the token kinds values.
34 */
35export type TokenKindEnum = _TokenKind[keyof _TokenKind];