Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(17)

Unified Diff: src/ic/ic.cc

Issue 1491223002: [turbofan] Desugar JSUnaryNot(x) to Select(x, false, true). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix typo in arm64. Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | test/unittests/compiler/js-operator-unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic/ic.cc
diff --git a/src/ic/ic.cc b/src/ic/ic.cc
index 7458551dbfe492da03c00701066bfea30582b701..3a6311b9e2f2d2be078ca9f7632a42a3576c6662 100644
--- a/src/ic/ic.cc
+++ b/src/ic/ic.cc
@@ -2813,7 +2813,7 @@ Handle<Object> ToBooleanIC::ToBoolean(Handle<Object> object) {
bool to_boolean_value = stub.UpdateStatus(object);
Handle<Code> code = stub.GetCode();
set_target(*code);
- return handle(Smi::FromInt(to_boolean_value ? 1 : 0), isolate());
+ return isolate()->factory()->ToBoolean(to_boolean_value);
}
« no previous file with comments | « src/full-codegen/x64/full-codegen-x64.cc ('k') | test/unittests/compiler/js-operator-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698