OLD | NEW |
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" |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
221 } | 221 } |
222 | 222 |
223 | 223 |
224 void AstPrinter::VisitBinaryOpNode(BinaryOpNode* node) { | 224 void AstPrinter::VisitBinaryOpNode(BinaryOpNode* node) { |
225 THR_Print("(%s %s ", node->Name(), node->TokenName()); | 225 THR_Print("(%s %s ", node->Name(), node->TokenName()); |
226 node->VisitChildren(this); | 226 node->VisitChildren(this); |
227 THR_Print(")"); | 227 THR_Print(")"); |
228 } | 228 } |
229 | 229 |
230 | 230 |
231 void AstPrinter::VisitBinaryOpWithMask32Node(BinaryOpWithMask32Node* node) { | |
232 THR_Print("(%s %s ", node->Name(), node->TokenName()); | |
233 node->VisitChildren(this); | |
234 THR_Print(" & \"0x%" Px64 "", node->mask32()); | |
235 THR_Print("\")"); | |
236 } | |
237 | |
238 | |
239 void AstPrinter::VisitUnaryOpNode(UnaryOpNode* node) { | 231 void AstPrinter::VisitUnaryOpNode(UnaryOpNode* node) { |
240 THR_Print("(%s %s ", node->Name(), node->TokenName()); | 232 THR_Print("(%s %s ", node->Name(), node->TokenName()); |
241 node->VisitChildren(this); | 233 node->VisitChildren(this); |
242 THR_Print(")"); | 234 THR_Print(")"); |
243 } | 235 } |
244 | 236 |
245 | 237 |
246 void AstPrinter::VisitConditionalExprNode(ConditionalExprNode* node) { | 238 void AstPrinter::VisitConditionalExprNode(ConditionalExprNode* node) { |
247 VisitGenericAstNode(node); | 239 VisitGenericAstNode(node); |
248 } | 240 } |
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
569 const char* function_name = | 561 const char* function_name = |
570 parsed_function.function().ToFullyQualifiedCString(); | 562 parsed_function.function().ToFullyQualifiedCString(); |
571 THR_Print("Ast for function '%s' {\n", function_name); | 563 THR_Print("Ast for function '%s' {\n", function_name); |
572 node_sequence->Visit(&ast_printer); | 564 node_sequence->Visit(&ast_printer); |
573 THR_Print("}\n"); | 565 THR_Print("}\n"); |
574 } | 566 } |
575 | 567 |
576 } // namespace dart | 568 } // namespace dart |
577 | 569 |
578 #endif // !defined(PRODUCT) | 570 #endif // !defined(PRODUCT) |
OLD | NEW |