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

Unified Diff: src/objects.cc

Issue 1196193014: Do not add extra argument for new.target (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Comment added Created 5 years, 6 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
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index f2d617b8298e93d45d9dfb580f8549a7bfbfb0fa..86fee8ed50b08f5aa1c038abe50e5112d984540e 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -10616,12 +10616,7 @@ void SharedFunctionInfo::DisableOptimization(BailoutReason reason) {
void SharedFunctionInfo::InitFromFunctionLiteral(
Handle<SharedFunctionInfo> shared_info, FunctionLiteral* lit) {
shared_info->set_length(lit->scope()->default_function_length());
- if (IsSubclassConstructor(lit->kind())) {
- shared_info->set_internal_formal_parameter_count(lit->parameter_count() +
- 1);
- } else {
- shared_info->set_internal_formal_parameter_count(lit->parameter_count());
- }
+ shared_info->set_internal_formal_parameter_count(lit->parameter_count());
shared_info->set_function_token_position(lit->function_token_position());
shared_info->set_start_position(lit->start_position());
shared_info->set_end_position(lit->end_position());

Powered by Google App Engine
This is Rietveld 408576698