Index: src/compiler/js-typed-lowering.cc |
diff --git a/src/compiler/js-typed-lowering.cc b/src/compiler/js-typed-lowering.cc |
index 64663df9aec4d553d9ba8ae2fd018c08ec728b55..0cf53373f637645ce74f73cdd5a367e23c495d08 100644 |
--- a/src/compiler/js-typed-lowering.cc |
+++ b/src/compiler/js-typed-lowering.cc |
@@ -587,19 +587,19 @@ Reduction JSTypedLowering::Reduce(Node* node) { |
Reduction result = ReduceJSToBooleanInput(node->InputAt(0)); |
Node* value; |
if (result.Changed()) { |
- // !x => BooleanNot(x) |
+ // JSUnaryNot(x) => BooleanNot(x) |
value = |
graph()->NewNode(simplified()->BooleanNot(), result.replacement()); |
NodeProperties::ReplaceWithValue(node, value); |
return Changed(value); |
} else { |
- // !x => BooleanNot(JSToBoolean(x)) |
+ // JSUnaryNot(x) => BooleanNot(JSToBoolean(x)) |
value = graph()->NewNode(simplified()->BooleanNot(), node); |
node->set_op(javascript()->ToBoolean()); |
NodeProperties::ReplaceWithValue(node, value, node); |
// Note: ReplaceUses() smashes all uses, so smash it back here. |
value->ReplaceInput(0, node); |
- return ReplaceWith(value); |
+ return Changed(node); |
} |
} |
case IrOpcode::kJSToBoolean: |