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

Unified Diff: pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart

Issue 1562893002: dart2js cps: Generate increment and compound operators. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Also compound string concatenation Created 4 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/tree_ir/tree_ir_nodes.dart
diff --git a/pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart b/pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart
index 215cf3ae74021c00eb6d418bf3115a24631acb35..eaa24e961fdbd4483df98ecb56327d46c23e950c 100644
--- a/pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart
+++ b/pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart
@@ -743,7 +743,11 @@ class SetField extends Expression {
Element field;
Expression value;
- SetField(this.object, this.field, this.value);
+ /// If non-null, this is a compound assignment to the field, using the given
+ /// operator. The operator must be a compoundable operator.
+ BuiltinOperator compound;
+
+ SetField(this.object, this.field, this.value, {this.compound});
accept(ExpressionVisitor visitor) => visitor.visitSetField(this);
accept1(ExpressionVisitor1 visitor, arg) => visitor.visitSetField(this, arg);
@@ -813,8 +817,9 @@ class SetIndex extends Expression {
Expression object;
Expression index;
Expression value;
+ BuiltinOperator compound;
- SetIndex(this.object, this.index, this.value);
+ SetIndex(this.object, this.index, this.value, {this.compound});
accept(ExpressionVisitor v) => v.visitSetIndex(this);
accept1(ExpressionVisitor1 v, arg) => v.visitSetIndex(this, arg);

Powered by Google App Engine
This is Rietveld 408576698