mirror of
https://github.com/python/cpython.git
synced 2025-07-28 13:44:43 +00:00
Fix a bug in the `compiler
` package that caused invalid code to be
generated for generator expressions.
This commit is contained in:
parent
7ae354846f
commit
4c6b0d5bec
5 changed files with 26 additions and 9 deletions
|
@ -583,11 +583,9 @@ class GenExpr(Node):
|
|||
def __init__(self, code, lineno=None):
|
||||
self.code = code
|
||||
self.lineno = lineno
|
||||
self.argnames = ['[outmost-iterable]']
|
||||
self.argnames = ['.0']
|
||||
self.varargs = self.kwargs = None
|
||||
|
||||
|
||||
|
||||
def getChildren(self):
|
||||
return self.code,
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue