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

Side by Side Diff: src/ast/ast-numbering.cc

Issue 2540593003: Move desugaring of super calls with trailing spread to one runtime call. (Closed)
Patch Set: Address comments Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/ast/ast-numbering.h" 5 #include "src/ast/ast-numbering.h"
6 6
7 #include "src/ast/ast.h" 7 #include "src/ast/ast.h"
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after
387 387
388 388
389 void AstNumberingVisitor::VisitCompareOperation(CompareOperation* node) { 389 void AstNumberingVisitor::VisitCompareOperation(CompareOperation* node) {
390 IncrementNodeCount(); 390 IncrementNodeCount();
391 node->set_base_id(ReserveIdRange(CompareOperation::num_ids())); 391 node->set_base_id(ReserveIdRange(CompareOperation::num_ids()));
392 Visit(node->left()); 392 Visit(node->left());
393 Visit(node->right()); 393 Visit(node->right());
394 ReserveFeedbackSlots(node); 394 ReserveFeedbackSlots(node);
395 } 395 }
396 396
397 397 void AstNumberingVisitor::VisitSpread(Spread* node) {
398 void AstNumberingVisitor::VisitSpread(Spread* node) { UNREACHABLE(); } 398 IncrementNodeCount();
399 399 node->set_base_id(ReserveIdRange(Spread::num_ids()));
400 Visit(node->expression());
401 }
400 402
401 void AstNumberingVisitor::VisitEmptyParentheses(EmptyParentheses* node) { 403 void AstNumberingVisitor::VisitEmptyParentheses(EmptyParentheses* node) {
402 UNREACHABLE(); 404 UNREACHABLE();
403 } 405 }
404 406
405 407
406 void AstNumberingVisitor::VisitForInStatement(ForInStatement* node) { 408 void AstNumberingVisitor::VisitForInStatement(ForInStatement* node) {
407 IncrementNodeCount(); 409 IncrementNodeCount();
408 DisableSelfOptimization(); 410 DisableSelfOptimization();
409 node->set_base_id(ReserveIdRange(ForInStatement::num_ids())); 411 node->set_base_id(ReserveIdRange(ForInStatement::num_ids()));
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
621 } 623 }
622 624
623 625
624 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone, 626 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone,
625 FunctionLiteral* function) { 627 FunctionLiteral* function) {
626 AstNumberingVisitor visitor(isolate, zone); 628 AstNumberingVisitor visitor(isolate, zone);
627 return visitor.Renumber(function); 629 return visitor.Renumber(function);
628 } 630 }
629 } // namespace internal 631 } // namespace internal
630 } // namespace v8 632 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/interpreter/bytecode-generator.cc » ('j') | src/interpreter/bytecode-generator.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698