classes and functions are new statements and should never get removed by the error recovery.
This commit is contained in:
1 parent
128dbd34b6
commit
31600b9552
3 files changed
+9
-2
No files matched your search
@@ -216,6 +216,7 @@ class Parser(object):
|
||||
# No success finding a transition
|
||||
print('err', tokenize.tok_name[typ], repr(value), start_pos, len(stack), index)
|
||||
self._stack_removal(grammar, stack, index + 1, value, start_pos)
|
||||
return value not in ('def', 'class')
|
||||
|
||||
def _stack_removal(self, grammar, stack, start_index, value, start_pos):
|
||||
def clear_names(children):
|
||||
|
||||
Reference in new issue
Block a user