| Index: pkg/compiler/lib/src/deferred_load.dart
|
| diff --git a/pkg/compiler/lib/src/deferred_load.dart b/pkg/compiler/lib/src/deferred_load.dart
|
| index b45d301226f580f996426d25a8b5fe5148c3078f..00d26365a2be87f557b595a821161e8f95053656 100644
|
| --- a/pkg/compiler/lib/src/deferred_load.dart
|
| +++ b/pkg/compiler/lib/src/deferred_load.dart
|
| @@ -182,12 +182,22 @@ class DeferredLoadTask extends CompilerTask {
|
| return _elementToOutputUnit[element];
|
| }
|
|
|
| + /// Direct access to the output-unit to element relation used for testing.
|
| + OutputUnit getOutputUnitForElementForTesting(Element element) {
|
| + return _elementToOutputUnit[element];
|
| + }
|
| +
|
| /// Returns the [OutputUnit] where [constant] belongs.
|
| OutputUnit outputUnitForConstant(ConstantValue constant) {
|
| if (!isProgramSplit) return mainOutputUnit;
|
| return _constantToOutputUnit[constant];
|
| }
|
|
|
| + /// Direct access to the output-unit to constants map used for testing.
|
| + Map<ConstantValue, OutputUnit> get outputUnitForConstantsForTesting {
|
| + return _constantToOutputUnit;
|
| + }
|
| +
|
| bool isDeferred(Element element) {
|
| return outputUnitForElement(element) != mainOutputUnit;
|
| }
|
| @@ -350,7 +360,7 @@ class DeferredLoadTask extends CompilerTask {
|
| treeElements
|
| .forEachConstantNode((Node node, ConstantExpression expression) {
|
| if (compiler.serialization.isDeserialized(analyzableElement)) {
|
| - if (!expression.isImplicit && !expression.isPotential) {
|
| + if (!expression.isPotential) {
|
| // Enforce evaluation of [expression].
|
| backend.constants.getConstantValue(expression);
|
| }
|
| @@ -928,7 +938,8 @@ class DeferredLoadTask extends CompilerTask {
|
|
|
| StringBuffer sb = new StringBuffer();
|
| for (OutputUnit outputUnit in allOutputUnits) {
|
| - sb.write(outputUnit.name);
|
| + sb.write('\n-------------------------------\n');
|
| + sb.write('Output unit: ${outputUnit.name}');
|
| List<String> elements = elementMap[outputUnit];
|
| if (elements != null) {
|
| sb.write('\n elements:');
|
|
|