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

Unified Diff: src/builtins/builtins.cc

Issue 2448993002: [turbofan]: Convert StringFromCharCode to var-args style TF builtin (Closed)
Patch Set: Rebase to ToT Created 4 years, 1 month 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
Index: src/builtins/builtins.cc
diff --git a/src/builtins/builtins.cc b/src/builtins/builtins.cc
index 8e32cc57796ecaa7343bb6c4d86666e97e3c8e06..ff2cf5e885a65eb7d024c9a2449bfa5f70016d0d 100644
--- a/src/builtins/builtins.cc
+++ b/src/builtins/builtins.cc
@@ -84,7 +84,7 @@ Code* BuildWithCodeStubAssemblerJS(Isolate* isolate,
Code::Flags flags, const char* name) {
HandleScope scope(isolate);
Zone zone(isolate->allocator(), ZONE_NAME);
- const int argc_with_recv = argc + 1;
+ const int argc_with_recv = (argc == -1) ? 0 : argc + 1;
CodeStubAssembler assembler(isolate, &zone, argc_with_recv, flags, name);
generator(&assembler);
Handle<Code> code = assembler.GenerateCode();

Powered by Google App Engine
This is Rietveld 408576698