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

Unified Diff: editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/ParseLibraryFileEvent.java

Issue 10389074: Cache unresolved units separately from libraries (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 7 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
Index: editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/ParseLibraryFileEvent.java
===================================================================
--- editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/ParseLibraryFileEvent.java (revision 7495)
+++ editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/ParseLibraryFileEvent.java (working copy)
@@ -24,14 +24,16 @@
public class ParseLibraryFileEvent {
private final Library library;
+ private final DartUnit unit;
/**
* Construct a new instance
*
* @param library the library (not <code>null</code>)
*/
- ParseLibraryFileEvent(Library library) {
+ ParseLibraryFileEvent(Library library, DartUnit unit) {
this.library = library;
+ this.unit = unit;
}
/**
@@ -61,6 +63,6 @@
* does not exist)
*/
public DartUnit getUnit() {
- return library.getCachedUnit(library.getFile());
+ return unit;
}
}

Powered by Google App Engine
This is Rietveld 408576698