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

Side by Side Diff: runtime/vm/ast_printer.cc

Issue 8490019: Capturing for loop variables correctly (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/ast.h ('k') | runtime/vm/code_generator.h » ('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 (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/ast_printer.h" 5 #include "vm/ast_printer.h"
6 6
7 #include "vm/handles.h" 7 #include "vm/handles.h"
8 #include "vm/object.h" 8 #include "vm/object.h"
9 #include "vm/os.h" 9 #include "vm/os.h"
10 #include "vm/parser.h" 10 #include "vm/parser.h"
(...skipping 19 matching lines...) Expand all
30 // CodeGeneratorContext. 30 // CodeGeneratorContext.
31 ASSERT(node_sequence != NULL); 31 ASSERT(node_sequence != NULL);
32 for (int i = 0; i < node_sequence->length(); i++) { 32 for (int i = 0; i < node_sequence->length(); i++) {
33 OS::Print("id %d: ", node_sequence->NodeAt(i)->id()); 33 OS::Print("id %d: ", node_sequence->NodeAt(i)->id());
34 node_sequence->NodeAt(i)->Visit(this); 34 node_sequence->NodeAt(i)->Visit(this);
35 OS::Print("\n"); 35 OS::Print("\n");
36 } 36 }
37 } 37 }
38 38
39 39
40 void AstPrinter::VisitCloneContextNode(CloneContextNode* node) {
41 VisitGenericAstNode(node);
42 }
43
44
40 void AstPrinter::VisitArgumentListNode(ArgumentListNode* arguments) { 45 void AstPrinter::VisitArgumentListNode(ArgumentListNode* arguments) {
41 VisitGenericAstNode(arguments); 46 VisitGenericAstNode(arguments);
42 } 47 }
43 48
44 49
45 void AstPrinter::VisitReturnNode(ReturnNode* node) { 50 void AstPrinter::VisitReturnNode(ReturnNode* node) {
46 VisitGenericAstNode(node); 51 VisitGenericAstNode(node);
47 } 52 }
48 53
49 54
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 ASSERT(node_sequence != NULL); 468 ASSERT(node_sequence != NULL);
464 AstPrinter ast_printer; 469 AstPrinter ast_printer;
465 const char* function_name = 470 const char* function_name =
466 parsed_function.function().ToFullyQualifiedCString(); 471 parsed_function.function().ToFullyQualifiedCString();
467 OS::Print("Ast for function '%s' {\n", function_name); 472 OS::Print("Ast for function '%s' {\n", function_name);
468 node_sequence->Visit(&ast_printer); 473 node_sequence->Visit(&ast_printer);
469 OS::Print("}\n"); 474 OS::Print("}\n");
470 } 475 }
471 476
472 } // namespace dart 477 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/ast.h ('k') | runtime/vm/code_generator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698