| Index: pkg/compiler/lib/src/compile_time_constants.dart
|
| diff --git a/pkg/compiler/lib/src/compile_time_constants.dart b/pkg/compiler/lib/src/compile_time_constants.dart
|
| index 564a8a3138c4aad1f287b68d48ff728fefdc55c4..f2bc14c59954d526335a22303c8b2ae20b30fbbd 100644
|
| --- a/pkg/compiler/lib/src/compile_time_constants.dart
|
| +++ b/pkg/compiler/lib/src/compile_time_constants.dart
|
| @@ -20,6 +20,7 @@ import 'dart_types.dart';
|
| import 'elements/elements.dart';
|
| import 'elements/modelx.dart' show
|
| FunctionElementX;
|
| +import 'helpers/helpers.dart';
|
| import 'resolution/tree_elements.dart' show
|
| TreeElements;
|
| import 'resolution/operators.dart';
|
| @@ -858,10 +859,10 @@ class CompileTimeConstantEvaluator extends Visitor<AstConstant> {
|
| concreteArguments = normalizedArguments;
|
| }
|
|
|
| - if (target == compiler.intEnvironment ||
|
| - target == compiler.boolEnvironment ||
|
| - target == compiler.stringEnvironment) {
|
| - return createFromEnvironmentConstant(node, constructedType, target,
|
| + if (constructor == compiler.intEnvironment ||
|
| + constructor == compiler.boolEnvironment ||
|
| + constructor == compiler.stringEnvironment) {
|
| + return createFromEnvironmentConstant(node, constructedType, constructor,
|
| callStructure, normalizedArguments, concreteArguments);
|
| } else {
|
| return makeConstructedConstant(compiler, handler, context, node, type,
|
| @@ -946,6 +947,7 @@ class CompileTimeConstantEvaluator extends Visitor<AstConstant> {
|
| expression =
|
| new StringFromEnvironmentConstantExpression(name, defaultValue);
|
| }
|
| + assert(expression != null);
|
| return new AstConstant(context, node, expression, value);
|
| }
|
|
|
|
|