[][src]Module dark_vm::tokens

The Tokens module, which contains the Token struct and the TokenKind enum. These describe the various tokens that can be recognized.

Modules

token

The token module, which contains the Token struct. This struct maintains the position and the kind of the token. These are generated by the lexer. The Token struct holds the tokens that are generated by the Lexer. The Token struct maintains the position where the token was generated and the value of the token. Using an enum for the values increases the readibility of the code.

token_kind

The token_kind module, which contains the TokenKind enum. This enum describes the various kinds of tokens that are recognized. The TokenKind enum maintains all of the different Tokens that could occur within the program. Using an enum allows for easy extensibility.