diff options
author | yui-knk <spiketeika@gmail.com> | 2023-11-18 17:46:38 +0900 |
---|---|---|
committer | Yuichiro Kaneko <spiketeika@gmail.com> | 2023-11-18 19:38:55 +0900 |
commit | c56dd94db0001b900a2dab3ee350a182d6bb42af (patch) | |
tree | 7a4f5236452ae721f67fe6602f3dcbc68a085ac1 /tool/lrama/lib/lrama/context.rb | |
parent | f479e629ab497f325091096819fa5bf60c0d03b2 (diff) | |
download | ruby-c56dd94db0001b900a2dab3ee350a182d6bb42af.tar.gz |
Lrama v0.5.10
Diffstat (limited to 'tool/lrama/lib/lrama/context.rb')
-rw-r--r-- | tool/lrama/lib/lrama/context.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/tool/lrama/lib/lrama/context.rb b/tool/lrama/lib/lrama/context.rb index 3d05c1f36e..895290a2bb 100644 --- a/tool/lrama/lib/lrama/context.rb +++ b/tool/lrama/lib/lrama/context.rb @@ -309,10 +309,8 @@ module Lrama # Index is sequence number of nterm, value is state id # of a default nterm transition destination. @yydefgoto = Array.new(@states.nterms.count, 0) - h = {} # Mapping from nterm to next_states nterm_to_next_states = {} - terms_count = @states.terms.count @states.states.each do |state| state.nterm_transitions.each do |shift, next_state| @@ -369,7 +367,7 @@ module Lrama end j = @sorted_actions.count - 1 - state_id, froms_and_tos, count, width = action + _state_id, _froms_and_tos, count, width = action while (j >= 0) do case |