mirror of
https://github.com/python/cpython.git
synced 2025-08-29 13:15:11 +00:00
SF patch 1547796 by Georg Brandl -- set literals.
This commit is contained in:
parent
ecfd0b2f3b
commit
86e58e239e
22 changed files with 229 additions and 72 deletions
|
@ -1241,6 +1241,12 @@ class CodeGenerator:
|
|||
self.visit(elt)
|
||||
self.emit('BUILD_LIST', len(node.nodes))
|
||||
|
||||
def visitSet(self, node):
|
||||
self.set_lineno(node)
|
||||
for elt in node.items:
|
||||
self.visit(elt)
|
||||
self.emit('BUILD_SET', len(node.items))
|
||||
|
||||
def visitSliceobj(self, node):
|
||||
for child in node.nodes:
|
||||
self.visit(child)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue