Index: dart/sdk/lib/_internal/compiler/implementation/elements/modelx.dart |
diff --git a/dart/sdk/lib/_internal/compiler/implementation/elements/modelx.dart b/dart/sdk/lib/_internal/compiler/implementation/elements/modelx.dart |
index 8c43df5589a77a52f70df93cf77e2121ced29cc7..87cc5ef369388e25e2bfff233eb6d4b1d7e3c1df 100644 |
--- a/dart/sdk/lib/_internal/compiler/implementation/elements/modelx.dart |
+++ b/dart/sdk/lib/_internal/compiler/implementation/elements/modelx.dart |
@@ -5,6 +5,7 @@ |
library elements.modelx; |
import 'dart:uri'; |
+import 'dart:collection' show LinkedHashMap; |
import 'elements.dart'; |
import '../../compiler.dart' as api; |
@@ -564,6 +565,9 @@ class LibraryElementX extends ElementX implements LibraryElement { |
*/ |
Link<Element> slotForExports; |
+ final Map<LibraryDependency, LibraryElement> tagMapping = |
+ new LinkedHashMap<LibraryDependency, LibraryElement>(); |
+ |
LibraryElementX(Script script, [Uri canonicalUri, LibraryElement this.origin]) |
: this.canonicalUri = ((canonicalUri == null) ? script.uri : canonicalUri), |
importScope = new Map<SourceString, Element>(), |
@@ -590,6 +594,13 @@ class LibraryElementX extends ElementX implements LibraryElement { |
tags = tags.prepend(tag); |
} |
+ void resolvedTag(LibraryDependency tag, LibraryElement library) { |
+ assert(tagMapping[tag] == null); |
+ tagMapping[tag] = library; |
+ } |
+ |
+ LibraryElement getDependency(LibraryDependency tag) => tagMapping[tag]; |
+ |
/** |
* Adds [element] to the import scope of this library. |
* |