mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
Merge of the release22 branch changes back into the trunk.
This commit is contained in:
parent
87fa3aa12c
commit
52acb49298
7 changed files with 80 additions and 7 deletions
|
@ -282,6 +282,21 @@ class Module(Node):
|
|||
def __repr__(self):
|
||||
return "Module(%s, %s)" % (repr(self.doc), repr(self.node))
|
||||
|
||||
class Expression(Node):
|
||||
# Expression is an artifical node class to support "eval"
|
||||
nodes["expression"] = "Expression"
|
||||
def __init__(self, node):
|
||||
self.node = node
|
||||
|
||||
def getChildren(self):
|
||||
return self.node,
|
||||
|
||||
def getChildNodes(self):
|
||||
return self.node,
|
||||
|
||||
def __repr__(self):
|
||||
return "Expression(%s)" % (repr(self.node))
|
||||
|
||||
class UnaryAdd(Node):
|
||||
nodes["unaryadd"] = "UnaryAdd"
|
||||
def __init__(self, expr):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue