Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(79)

Unified Diff: client/fling/src/java/core/com/google/dart/LibraryFromSources.java

Issue 8284001: Libraries cannot source themselves anymore. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Minor cleanup. Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/fling/src/java/core/com/google/dart/LibraryFromSources.java
diff --git a/client/fling/src/java/core/com/google/dart/LibraryFromSources.java b/client/fling/src/java/core/com/google/dart/LibraryFromSources.java
index 5d029c8f1dcd5a9cf87beaac4224d3da049e66e7..6ff41142f281415af68e9113f8a61708dbdbb7ad 100644
--- a/client/fling/src/java/core/com/google/dart/LibraryFromSources.java
+++ b/client/fling/src/java/core/com/google/dart/LibraryFromSources.java
@@ -28,7 +28,6 @@ public class LibraryFromSources implements LibrarySource, DartSource {
for (LibrarySource lib : libs) {
this.libs.put(lib.getName(), lib);
}
- sources.put(name, this);
}
public void addNative(DartSource source) {
@@ -61,6 +60,10 @@ public class LibraryFromSources implements LibrarySource, DartSource {
@Override
public DartSource getSourceFor(String path) {
+ if (name.equals(path)) {
+ return this;
+ }
+
final DartSource source = sources.get(path);
if (source != null) {
return source;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698