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

Unified Diff: pkg/compiler/lib/src/constants/expressions.dart

Issue 2118203002: Correct evaluation of interpolated `null` (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 5 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 | tests/compiler/dart2js/constant_expression_evaluate_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/constants/expressions.dart
diff --git a/pkg/compiler/lib/src/constants/expressions.dart b/pkg/compiler/lib/src/constants/expressions.dart
index a6317d5f9830ec8b4f83ca003228f7b309cf15c4..e3058661915fbe0583142d597365682120bfee33 100644
--- a/pkg/compiler/lib/src/constants/expressions.dart
+++ b/pkg/compiler/lib/src/constants/expressions.dart
@@ -663,7 +663,7 @@ class ConcatenateConstantExpression extends ConstantExpression {
for (ConstantExpression expression in expressions) {
ConstantValue value = expression.evaluate(environment, constantSystem);
DartString valueString;
- if (value.isNum || value.isBool) {
+ if (value.isNum || value.isBool || value.isNull) {
PrimitiveConstantValue primitive = value;
valueString =
new DartString.literal(primitive.primitiveValue.toString());
« no previous file with comments | « no previous file | tests/compiler/dart2js/constant_expression_evaluate_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698