Commit 8931a015 authored by Stefan Behnel's avatar Stefan Behnel

minor code cleanup

parent e8fb800c
...@@ -3234,10 +3234,10 @@ class ConstantFolding(Visitor.VisitorTransform, SkipDeclarations): ...@@ -3234,10 +3234,10 @@ class ConstantFolding(Visitor.VisitorTransform, SkipDeclarations):
target_class = self._widest_node_class(operand1, operand2) target_class = self._widest_node_class(operand1, operand2)
if target_class is None: if target_class is None:
return node return node
if target_class is ExprNodes.BoolNode and node.operator in '+-//<<%**>>': elif target_class is ExprNodes.BoolNode and node.operator in '+-//<<%**>>':
# C arithmetic results in at least an int type # C arithmetic results in at least an int type
target_class = ExprNodes.IntNode target_class = ExprNodes.IntNode
if target_class is ExprNodes.CharNode and node.operator in '+-//<<%**>>&|^': elif target_class is ExprNodes.CharNode and node.operator in '+-//<<%**>>&|^':
# C arithmetic results in at least an int type # C arithmetic results in at least an int type
target_class = ExprNodes.IntNode target_class = ExprNodes.IntNode
......
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