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

Unified Diff: pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart

Issue 831133004: Use closure conversion in new dart2js backend. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebase Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart
diff --git a/pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart b/pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart
index 1a162c83e797bb244698aa21b2df7710e5cf5380..0e6dd308d5a7fb88f9e4b2a3ef047614777fbb30 100644
--- a/pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart
+++ b/pkg/compiler/lib/src/cps_ir/cps_ir_nodes_sexpr.dart
@@ -228,6 +228,30 @@ class SExpressionStringifier extends Visitor<String> with Indentation {
return '(IsTrue $value)';
}
+ String visitSetField(SetField node) {
+ String object = access(node.object);
+ String field = node.field.name;
+ String value = access(node.value);
+ String body = indentBlock(() => visit(node.body));
+ return '$indentation(SetField $object.$field = $value in\n$body)';
Kevin Millikin (Google) 2015/01/13 08:25:36 I don't really want '.', '=', or 'in' here. This
asgerf 2015/01/13 10:04:26 Yeah, I must have been half-thinking about the IR
+ }
+
+ String visitGetField(GetField node) {
+ String object = access(node.object);
+ String field = node.field.toString();
+ return '(GetField $object.$field)';
Kevin Millikin (Google) 2015/01/13 08:25:36 No dot: '(GetField $object $field)'
+ }
+
+ String visitCreateBox(CreateBox node) {
+ return '(CreateBox)';
+ }
+
+ String visitCreateClosureClass(CreateClosureClass node) {
+ String className = node.classElement.name;
+ String arguments = node.arguments.map(access).join(' ');
+ return '(CreateClosureClass $className $arguments)';
Kevin Millikin (Google) 2015/01/13 08:25:36 '(CreateClosureClass $className ($arguments))'
+ }
+
String visitIdentical(Identical node) {
String left = access(node.left);
String right = access(node.right);

Powered by Google App Engine
This is Rietveld 408576698