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

Unified Diff: pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart

Issue 2668893003: Kernel: Do not try to use return value of []= (Closed)
Patch Set: Created 3 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
« no previous file with comments | « no previous file | pkg/kernel/lib/frontend/accessors.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
diff --git a/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart b/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
index 86a44b09d0e3a4af9734e923a63970021d180828..1a805be3af3eac01683dbd25bb4cc0c7dec3e57e 100644
--- a/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
@@ -27,13 +27,13 @@ abstract class Accessor {
{bool voidContext: false}) {
if (voidContext) {
return _finish(new ConditionalExpression(buildIsNull(_makeRead()),
- _makeWrite(value, voidContext), new NullLiteral(), type));
+ _makeWrite(value, false), new NullLiteral(), type));
ahe 2017/02/01 14:02:38 I think this hits more cases than you expect, so I
kustermann 2017/02/01 14:23:42 The result of _makeWrite() is used, namely in a Co
ahe 2017/02/01 14:33:16 I was wrong. Thank's for clarifying.
}
var tmp = new VariableDeclaration.forValue(_makeRead());
return _finish(makeLet(
tmp,
new ConditionalExpression(buildIsNull(new VariableGet(tmp)),
- _makeWrite(value, voidContext), new VariableGet(tmp), type)));
+ _makeWrite(value, false), new VariableGet(tmp), type)));
}
Expression buildCompoundAssignment(Name binaryOperator, Expression value,
« no previous file with comments | « no previous file | pkg/kernel/lib/frontend/accessors.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698