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

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

Issue 1753083003: Fix issue where errors aren't reported for a new overlay (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 10 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 | pkg/analyzer/lib/src/context/context.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 77c8d88f19111919b0c5007eafc80257e6ccea0c..2b509da14c522bf54880d519fb1cc84a042b01db 100644
--- a/pkg/analysis_server/lib/src/analysis_server.dart
+++ b/pkg/analysis_server/lib/src/analysis_server.dart
@@ -551,7 +551,8 @@ class AnalysisServer {
if (containingContext != null) {
Source source =
ContextManagerImpl.createSourceInContext(containingContext, file);
- return new ContextSourcePair(containingContext, source);
+ return new ContextSourcePair(containingContext, source,
+ contained: true);
}
}
// try to find a context that analysed the file
@@ -1262,7 +1263,8 @@ class AnalysisServer {
sources.forEach((Source source) {
anyContextUpdated = true;
if (context.handleContentsChanged(
- source, oldContents, newContents, true)) {
+ source, oldContents, newContents, true,
+ explicit: contextSource.contained)) {
skybrian 2016/03/02 06:35:34 Oops, this check should probably be something like
schedulePerformAnalysisOperation(context);
} else {
// When the client sends any change for a source, we should resend
@@ -1440,7 +1442,13 @@ class ContextSourcePair {
*/
final Source source;
- ContextSourcePair(this.context, this.source);
+ /**
+ * If true, the source is contained within the directory associated
+ * with the context.
+ */
+ final bool contained;
+
+ ContextSourcePair(this.context, this.source, {this.contained: false});
}
/**
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/context/context.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698