diff --git a/lib/lrama/grammar.rb b/lib/lrama/grammar.rb index 03944d74..91685530 100644 --- a/lib/lrama/grammar.rb +++ b/lib/lrama/grammar.rb @@ -489,6 +489,7 @@ def create_token(type, s_value, line, column) return t end + private def find_nterm_by_id!(id) @@ -653,7 +654,9 @@ def collect_symbols # Fill #number and #token_id def fill_symbol_number - # TODO: why start from 256 + # Character literal in grammar file has + # token id corresponding to ASCII code by default, + # so start token_id from 256. token_id = 256 # YYEMPTY = -2