Changes for 3.8: sync_comp_for instead of comp_for
Please also look at the changes for parso in its b5d50392a4058919c0018666cdfc8c3eaaea9cb5 commit
This commit is contained in:
1 parent
f3364a458c
commit
42b6e20729
8 files changed
+48
-25
No files matched your search
@@ -247,7 +247,7 @@ def eval_atom(context, atom):
|
||||
except IndexError:
|
||||
pass
|
||||
|
||||
if comp_for.type == 'comp_for':
|
||||
if comp_for.type in ('comp_for', 'sync_comp_for'):
|
||||
return ContextSet([iterable.comprehension_from_atom(
|
||||
context.evaluator, context, atom
|
||||
)])
|
||||
@@ -588,7 +588,7 @@ def tree_name_to_contexts(evaluator, context, tree_name):
|
||||
if types:
|
||||
return types
|
||||
|
||||
if typ in ('for_stmt', 'comp_for'):
|
||||
if typ in ('for_stmt', 'comp_for', 'sync_comp_for'):
|
||||
try:
|
||||
types = context.predefined_names[node][tree_name.value]
|
||||
except KeyError:
|
||||
|
||||
Reference in new issue
Block a user