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

Unified Diff: pkg/analysis_server/lib/src/analysis_server.dart

Issue 787553002: invoke computeCache when priority sources change (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: merge Created 6 years 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 | pkg/analysis_server/lib/src/domain_completion.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/analysis_server.dart
diff --git a/pkg/analysis_server/lib/src/analysis_server.dart b/pkg/analysis_server/lib/src/analysis_server.dart
index 77cd21a135d67cff05cd629632f071f051875dba..c3af9c4955320afded35d11c3dcd16e6a0f8d30e 100644
--- a/pkg/analysis_server/lib/src/analysis_server.dart
+++ b/pkg/analysis_server/lib/src/analysis_server.dart
@@ -282,7 +282,14 @@ class AnalysisServer {
}
}
// check if there is a context that analyzed this source
- Source source = getSource(path);
+ return getAnalysisContextForSource(getSource(path));
+ }
+
+ /**
+ * Return the [AnalysisContext] that is used to analyze the given [source].
+ * Return `null` if there is no such context.
+ */
+ AnalysisContext getAnalysisContextForSource(Source source) {
for (AnalysisContext context in folderMap.values) {
SourceKind kind = context.getKindOf(source);
if (kind != null) {
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/domain_completion.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698