Commit c7eebbaa authored by Stefan Behnel's avatar Stefan Behnel

let RemoveUnreachableCode discard any PassStatNodes (e.g. added by analysing...

let RemoveUnreachableCode discard any PassStatNodes (e.g. added by analysing declaration-only ExprStatNode)
parent 229279d6
...@@ -2148,6 +2148,10 @@ class RemoveUnreachableCode(CythonTransform): ...@@ -2148,6 +2148,10 @@ class RemoveUnreachableCode(CythonTransform):
break break
return node return node
def visit_PassStatNode(self, _):
# just in case
return None
def visit_IfClauseNode(self, node): def visit_IfClauseNode(self, node):
self.visitchildren(node) self.visitchildren(node)
if node.body.is_terminator: if node.body.is_terminator:
......
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