aboutsummaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorRyo Nihei <nihei.dev@gmail.com>2021-08-26 23:16:09 +0900
committerRyo Nihei <nihei.dev@gmail.com>2021-08-26 23:18:49 +0900
commit7271e46bbcb11acf860c91eddfe12dd7eed5ccad (patch)
treefafbf797ca806ff1e4cc68acaaaa6db66aec632d /spec
parentUpdate CHANGELOG (diff)
downloadcotia-7271e46bbcb11acf860c91eddfe12dd7eed5ccad.tar.gz
cotia-7271e46bbcb11acf860c91eddfe12dd7eed5ccad.tar.xz
Add error symbol and #recover directive to recover from an error state
Diffstat (limited to 'spec')
-rw-r--r--spec/grammar.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/spec/grammar.go b/spec/grammar.go
index 002fac9..7901957 100644
--- a/spec/grammar.go
+++ b/spec/grammar.go
@@ -33,6 +33,9 @@ type ParsingTable struct {
NonTerminals []string `json:"non_terminals"`
NonTerminalCount int `json:"non_terminal_count"`
EOFSymbol int `json:"eof_symbol"`
+ ErrorSymbol int `json:"error_symbol"`
+ ErrorTrapperStates []int `json:"error_trapper_states"`
+ RecoverProductions []int `json:"recover_productions"`
ExpectedTerminals [][]int `json:"expected_terminals"`
}