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

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

Issue 1715123003: - Add DEBUG_ONLY and NOT_IN_PRODUCT macros. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Update status files. Created 4 years, 10 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 | « runtime/tests/vm/vm.status ('k') | runtime/vm/compiler.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 (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/log.h" 8 #include "vm/log.h"
9 #include "vm/object.h" 9 #include "vm/object.h"
10 #include "vm/os.h" 10 #include "vm/os.h"
11 #include "vm/parser.h" 11 #include "vm/parser.h"
12 12
13 #if !defined(PRODUCT)
14
13 namespace dart { 15 namespace dart {
14 16
15 #ifndef PRODUCT
16
17 AstPrinter::AstPrinter() : indent_(0) { } 17 AstPrinter::AstPrinter() : indent_(0) { }
18 18
19 19
20 AstPrinter::~AstPrinter() { } 20 AstPrinter::~AstPrinter() { }
21 21
22 22
23 void AstPrinter::VisitGenericAstNode(AstNode* node) { 23 void AstPrinter::VisitGenericAstNode(AstNode* node) {
24 THR_Print("(%s ", node->PrettyName()); 24 THR_Print("(%s ", node->PrettyName());
25 node->VisitChildren(this); 25 node->VisitChildren(this);
26 THR_Print(")"); 26 THR_Print(")");
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
569 SequenceNode* node_sequence = parsed_function.node_sequence(); 569 SequenceNode* node_sequence = parsed_function.node_sequence();
570 ASSERT(node_sequence != NULL); 570 ASSERT(node_sequence != NULL);
571 AstPrinter ast_printer; 571 AstPrinter ast_printer;
572 const char* function_name = 572 const char* function_name =
573 parsed_function.function().ToFullyQualifiedCString(); 573 parsed_function.function().ToFullyQualifiedCString();
574 THR_Print("Ast for function '%s' {\n", function_name); 574 THR_Print("Ast for function '%s' {\n", function_name);
575 node_sequence->Visit(&ast_printer); 575 node_sequence->Visit(&ast_printer);
576 THR_Print("}\n"); 576 THR_Print("}\n");
577 } 577 }
578 578
579 #endif // !PRODUCT 579 } // namespace dart
580 580
581 } // namespace dart 581 #endif // !defined(PRODUCT)
OLDNEW
« no previous file with comments | « runtime/tests/vm/vm.status ('k') | runtime/vm/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698