diff options
author | Ryo Nihei <nihei.dev@gmail.com> | 2021-05-04 00:44:47 +0900 |
---|---|---|
committer | Ryo Nihei <nihei.dev@gmail.com> | 2021-05-04 00:44:47 +0900 |
commit | 8a37dfeb49435f36a791fa92a6618afd7f3584f9 (patch) | |
tree | 99ba1262b0c01f7c8d2fa5fbfe92c7eff3314d82 /compiler/dfa.go | |
parent | Generate an invalid token from incompleted input. (diff) | |
download | tre-8a37dfeb49435f36a791fa92a6618afd7f3584f9.tar.gz tre-8a37dfeb49435f36a791fa92a6618afd7f3584f9.tar.xz |
Add lex mode
lex mode is a feature that separates transition tables per each mode.
The lexer starts from an initial state indicated by `initial_state` field and
transitions between modes according to `push` and `pop` fields.
The initial state will always be `default`.
Currently, maleeni doesn't provide the ability to change the initial state.
You can specify the modes of each lex entry using `modes` field.
When the mode isn't indicated explicitly, the entries have `default` mode.
Diffstat (limited to 'compiler/dfa.go')
0 files changed, 0 insertions, 0 deletions