Index: pkg/compiler/lib/src/serialization/modelz.dart |
diff --git a/pkg/compiler/lib/src/serialization/modelz.dart b/pkg/compiler/lib/src/serialization/modelz.dart |
index c909f9acf56e4b26405ae9635102f41815c643d6..4c932f3d0dce8b3500a05055462ddac211163152 100644 |
--- a/pkg/compiler/lib/src/serialization/modelz.dart |
+++ b/pkg/compiler/lib/src/serialization/modelz.dart |
@@ -458,7 +458,8 @@ class LibraryElementZ extends DeserializedElementZ |
void _ensureExports() { |
if (_exportsMap == null) { |
- _exportsMap = new ListedContainer(_decoder.getElements(Key.EXPORT_SCOPE)); |
+ _exportsMap = new ListedContainer( |
+ _decoder.getElements(Key.EXPORT_SCOPE, isOptional: true)); |
} |
} |
@@ -2257,6 +2258,7 @@ class PrefixElementZ extends DeserializedElementZ |
implements PrefixElement { |
bool _isDeferred; |
ImportElement _deferredImport; |
+ GetterElement _loadLibrary; |
PrefixElementZ(ObjectDecoder decoder) : super(decoder); |
@@ -2266,7 +2268,10 @@ class PrefixElementZ extends DeserializedElementZ |
void _ensureDeferred() { |
if (_isDeferred == null) { |
_isDeferred = _decoder.getBool(Key.IS_DEFERRED); |
- _deferredImport = _decoder.getElement(Key.IMPORT, isOptional: true); |
+ if (_isDeferred) { |
+ _deferredImport = _decoder.getElement(Key.IMPORT); |
+ _loadLibrary = _decoder.getElement(Key.GETTER); |
+ } |
} |
} |
@@ -2283,6 +2288,11 @@ class PrefixElementZ extends DeserializedElementZ |
} |
@override |
+ GetterElement get loadLibrary { |
+ return _loadLibrary; |
+ } |
+ |
+ @override |
ElementKind get kind => ElementKind.PREFIX; |
@override |