Skip to content

Commit

Permalink
tweak: arrange token types enum
Browse files Browse the repository at this point in the history
  • Loading branch information
thutasann committed May 21, 2024
1 parent ac8349f commit 4497a4c
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/lexer/lexer.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,25 @@
* [letToken, IdentifierToken, EqualsToken, NumberToken]
*/
export enum TokenType {
//? ------ literal types
/** number */
Number,
/** identifier */
Identifier,

//? ------ Keywords
/** let to declare variable */
Let,

//? ------ Grouping * Operators
/** binary operator */
BinaryOperator,
/** equal */
Equals,
/** open parenthesis */
OpenParen,
/** close parenthesis */
CloseParen,
/** binary operator */
BinaryOperator,
/** let to declare variable */
Let,
/** signified the end of file */
EOF,
}
Expand Down

0 comments on commit 4497a4c

Please sign in to comment.