| Index: tools/lexer_generator/dfa_optimizer.py
|
| diff --git a/tools/lexer_generator/dfa_optimizer.py b/tools/lexer_generator/dfa_optimizer.py
|
| index 0b2c1e5136afe0e068d212f870449f11bb4afe80..2ac651da5ced87ca0b9236c4d0764c22a0658a5b 100644
|
| --- a/tools/lexer_generator/dfa_optimizer.py
|
| +++ b/tools/lexer_generator/dfa_optimizer.py
|
| @@ -149,10 +149,10 @@ class DfaOptimizer(object):
|
| assert not state_replacements
|
| self.__dfa.visit_all_states(replace_state)
|
| # now patch up all states with stores
|
| - for state in store_states:
|
| - old_action = states[state]['action']
|
| - match_action = ('do_stored_token', None)
|
| - states[state]['action'] = replacement_action(old_action, match_action)
|
| + for state_id in store_states:
|
| + old_action = states[state_id]['action']
|
| + match_action = ('do_stored_token', state_id)
|
| + states[state_id]['action'] = replacement_action(old_action, match_action)
|
| start_name = name(self.__dfa.start_state())
|
| if self.__log:
|
| print 'gotos inserted %s' % counters['gotos']
|
|
|