Index: compiler/java/com/google/dart/compiler/resolver/Elements.java |
diff --git a/compiler/java/com/google/dart/compiler/resolver/Elements.java b/compiler/java/com/google/dart/compiler/resolver/Elements.java |
index b95d48cd61da7120003192662e85f909a7290c82..a83dfe38bf4298d6e19798ca5a2e615bde830b6b 100644 |
--- a/compiler/java/com/google/dart/compiler/resolver/Elements.java |
+++ b/compiler/java/com/google/dart/compiler/resolver/Elements.java |
@@ -766,9 +766,17 @@ static FieldElementImplementation fieldFromNode(DartField node, |
|| Elements.isLibrarySource(source, "/core/core.dart"); |
} |
+ public static boolean isCollectionLibrarySource(Source source) { |
+ return Elements.isLibrarySource(source, "/collection/collection.dart"); |
+ } |
+ |
public static boolean isHtmlLibrarySource(Source source) { |
return Elements.isLibrarySource(source, "/html/dartium/html_dartium.dart"); |
} |
+ |
+ public static boolean isSourceName(Source source, String requiredName) { |
+ return source.getName().equals(requiredName); |
+ } |
/** |
* @return the {@link LibraryElement} which declares given {@link Element}. |