Kaydet (Commit) 01d12937 authored tarafından Jeremy Hylton's avatar Jeremy Hylton

[finishing fix from earlier checkins]

Call set_lineno() in visitDiscard(), which will generate linenos for
discard statements, e.g. the statement "1/0"

Fixes SF bug #409587
üst d91bbba8
......@@ -495,6 +495,7 @@ class CodeGenerator:
# misc
def visitDiscard(self, node):
self.set_lineno(node)
self.visit(node.expr)
self.emit('POP_TOP')
......
......@@ -495,6 +495,7 @@ class CodeGenerator:
# misc
def visitDiscard(self, node):
self.set_lineno(node)
self.visit(node.expr)
self.emit('POP_TOP')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment