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

Side by Side Diff: pkg/compiler/lib/src/kernel/kernel_debug.dart

Issue 2466353002: Revert "More functionality in kernel_impact." and "Compute NativeBehavior for foreign functions." (Closed)
Patch Set: Created 4 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 /// Helper for debug Kernel nodes. 5 /// Helper for debug Kernel nodes.
6 6
7 library kernel.debug; 7 library kernel.debug;
8 8
9 import 'package:kernel/kernel.dart'; 9 import 'package:kernel/kernel.dart';
10 import 'package:kernel/visitor.dart'; 10 import 'package:kernel/visitor.dart';
(...skipping 27 matching lines...) Expand all
38 38
39 @override 39 @override
40 void visitVariableGet(VariableGet node) { 40 void visitVariableGet(VariableGet node) {
41 openAndCloseNode( 41 openAndCloseNode(
42 node, '${node.runtimeType}', {'variable': '${node.variable}'}); 42 node, '${node.runtimeType}', {'variable': '${node.variable}'});
43 } 43 }
44 44
45 @override 45 @override
46 void visitVariableDeclaration(VariableDeclaration node) { 46 void visitVariableDeclaration(VariableDeclaration node) {
47 openNode(node, '${node.runtimeType}', { 47 openNode(node, '${node.runtimeType}', {
48 'name': '${node.name ?? '--unnamed--'}', 48 'name': '${node.name}',
49 'isFinal': '${node.isFinal}', 49 'isFinal': '${node.isFinal}',
50 'isConst': '${node.isConst}' 50 'isConst': '${node.isConst}'
51 }); 51 });
52 node.visitChildren(this); 52 node.visitChildren(this);
53 closeNode(); 53 closeNode();
54 } 54 }
55 55
56 @override 56 @override
57 void visitInterfaceType(InterfaceType node) { 57 void visitInterfaceType(InterfaceType node) {
58 openNode(node, '${node.runtimeType}', { 58 openNode(node, '${node.runtimeType}', {
59 'name': '${node.classNode.name}', 59 'name': '${node.classNode.name}',
60 }); 60 });
61 node.visitChildren(this); 61 node.visitChildren(this);
62 closeNode(); 62 closeNode();
63 } 63 }
64 64
65 /// Pretty-prints given node tree into string. 65 /// Pretty-prints given node tree into string.
66 static String prettyPrint(Node node) { 66 static String prettyPrint(Node node) {
67 var p = new DebugPrinter(); 67 var p = new DebugPrinter();
68 node.accept(p); 68 node.accept(p);
69 return p.sb.toString(); 69 return p.sb.toString();
70 } 70 }
71 } 71 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_backend/backend_helpers.dart ('k') | pkg/compiler/lib/src/native/behavior.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698