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

Side by Side Diff: src/ast/prettyprinter.cc

Issue 2212383003: Revert of Separate Scope into DeclarationScope and Scope (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « src/ast/prettyprinter.h ('k') | src/ast/scopeinfo.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/prettyprinter.h" 5 #include "src/ast/prettyprinter.h"
6 6
7 #include <stdarg.h> 7 #include <stdarg.h>
8 8
9 #include "src/ast/ast-value-factory.h" 9 #include "src/ast/ast-value-factory.h"
10 #include "src/ast/scopes.h" 10 #include "src/ast/scopes.h"
(...skipping 669 matching lines...) Expand 10 before | Expand all | Expand 10 after
680 680
681 void AstPrinter::PrintDeclarations(ZoneList<Declaration*>* declarations) { 681 void AstPrinter::PrintDeclarations(ZoneList<Declaration*>* declarations) {
682 if (declarations->length() > 0) { 682 if (declarations->length() > 0) {
683 IndentedScope indent(this, "DECLS"); 683 IndentedScope indent(this, "DECLS");
684 for (int i = 0; i < declarations->length(); i++) { 684 for (int i = 0; i < declarations->length(); i++) {
685 Visit(declarations->at(i)); 685 Visit(declarations->at(i));
686 } 686 }
687 } 687 }
688 } 688 }
689 689
690 void AstPrinter::PrintParameters(DeclarationScope* scope) { 690
691 void AstPrinter::PrintParameters(Scope* scope) {
691 if (scope->num_parameters() > 0) { 692 if (scope->num_parameters() > 0) {
692 IndentedScope indent(this, "PARAMS"); 693 IndentedScope indent(this, "PARAMS");
693 for (int i = 0; i < scope->num_parameters(); i++) { 694 for (int i = 0; i < scope->num_parameters(); i++) {
694 PrintLiteralWithModeIndented("VAR", scope->parameter(i), 695 PrintLiteralWithModeIndented("VAR", scope->parameter(i),
695 scope->parameter(i)->name()); 696 scope->parameter(i)->name());
696 } 697 }
697 } 698 }
698 } 699 }
699 700
700 701
(...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after
1189 1190
1190 void AstPrinter::VisitRewritableExpression(RewritableExpression* node) { 1191 void AstPrinter::VisitRewritableExpression(RewritableExpression* node) {
1191 Visit(node->expression()); 1192 Visit(node->expression());
1192 } 1193 }
1193 1194
1194 1195
1195 #endif // DEBUG 1196 #endif // DEBUG
1196 1197
1197 } // namespace internal 1198 } // namespace internal
1198 } // namespace v8 1199 } // namespace v8
OLDNEW
« no previous file with comments | « src/ast/prettyprinter.h ('k') | src/ast/scopeinfo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698