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

Unified Diff: src/builtins/builtins-regexp.cc

Issue 2381843002: Add Smi::Zero and replace all Smi::FromInt(0) calls (Closed)
Patch Set: Mark Smi::kZero as V8_EXPORT_PRIVATE 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/builtins/builtins-math.cc ('k') | src/builtins/builtins-string.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/builtins/builtins-regexp.cc
diff --git a/src/builtins/builtins-regexp.cc b/src/builtins/builtins-regexp.cc
index 554887b7dda31ba1d34dc1af0358ddf2b0dd3b2e..a121a951c9da4abf6ca8d99fed8c4e6545592e99 100644
--- a/src/builtins/builtins-regexp.cc
+++ b/src/builtins/builtins-regexp.cc
@@ -322,7 +322,7 @@ void Builtins::Generate_RegExpPrototypeExec(CodeStubAssembler* a) {
Node* const null = a->NullConstant();
Node* const int_zero = a->IntPtrConstant(0);
- Node* const smi_zero = a->SmiConstant(Smi::FromInt(0));
+ Node* const smi_zero = a->SmiConstant(Smi::kZero);
// Ensure {receiver} is a JSRegExp.
Node* const regexp_map = a->ThrowIfNotInstanceType(
« no previous file with comments | « src/builtins/builtins-math.cc ('k') | src/builtins/builtins-string.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698