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

Unified Diff: src/bootstrapper.cc

Issue 2396353002: Revert "Add Smi::Zero and replace all Smi::FromInt(0) calls" (Closed)
Patch Set: Created 4 years, 2 months 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/ast/scopeinfo.cc ('k') | src/builtins/arm/builtins-arm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/bootstrapper.cc
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc
index 94b9b24c4a90bf23b80732cd23b32aa96d147536..078f1e7c2474793f1f74e870ea7edc80ade00cdd 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -1318,7 +1318,7 @@ void Genesis::InitializeGlobal(Handle<JSGlobalObject> global_object,
// Create the %NumberPrototype%
Handle<JSValue> prototype =
Handle<JSValue>::cast(factory->NewJSObject(number_fun, TENURED));
- prototype->set_value(Smi::kZero);
+ prototype->set_value(Smi::FromInt(0));
Accessors::FunctionSetPrototype(number_fun, prototype).Assert();
// Install the "constructor" property on the {prototype}.
@@ -4215,7 +4215,7 @@ Genesis::Genesis(Isolate* isolate,
isolate->counters()->contexts_created_from_scratch()->Increment();
// Re-initialize the counter because it got incremented during snapshot
// creation.
- isolate->native_context()->set_errors_thrown(Smi::kZero);
+ isolate->native_context()->set_errors_thrown(Smi::FromInt(0));
}
// Install experimental natives. Do not include them into the
« no previous file with comments | « src/ast/scopeinfo.cc ('k') | src/builtins/arm/builtins-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698