Commit a33d1b67 authored by Stefan Behnel's avatar Stefan Behnel

micro fix for switch transform

parent d43413bd
...@@ -101,8 +101,8 @@ class FlattenInListTransform(Visitor.VisitorTransform): ...@@ -101,8 +101,8 @@ class FlattenInListTransform(Visitor.VisitorTransform):
else: else:
return node return node
args = node.operand2.args
if isinstance(node.operand2, ExprNodes.TupleNode) or isinstance(node.operand2, ExprNodes.ListNode): if isinstance(node.operand2, ExprNodes.TupleNode) or isinstance(node.operand2, ExprNodes.ListNode):
args = node.operand2.args
if len(args) == 0: if len(args) == 0:
return ExprNodes.BoolNode(pos = node.pos, value = node.operator == 'not_in') return ExprNodes.BoolNode(pos = node.pos, value = node.operator == 'not_in')
else: else:
......
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