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

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

Issue 981283003: Change all sources associated with changed files (issue 22680) (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 9 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/analysis_server/test/context_manager_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/context_manager.dart
diff --git a/pkg/analysis_server/lib/src/context_manager.dart b/pkg/analysis_server/lib/src/context_manager.dart
index 8af64b3f40d93bef9ec327223660860c200bfc75..1506fc5375a8b70ec664ecc07a1f2f8dcc837148 100644
--- a/pkg/analysis_server/lib/src/context_manager.dart
+++ b/pkg/analysis_server/lib/src/context_manager.dart
@@ -518,10 +518,12 @@ abstract class ContextManager {
}
break;
case ChangeType.MODIFY:
- Source source = info.sources[path];
- if (source != null) {
+ List<Source> sources = info.context.getSourcesWithFullName(path);
Paul Berry 2015/03/06 21:56:42 I just noticed that there's a pre-existing bug her
Brian Wilkerson 2015/03/06 23:17:11 Done.
+ if (!sources.isEmpty) {
ChangeSet changeSet = new ChangeSet();
- changeSet.changedSource(source);
+ sources.forEach((Source source) {
Paul Berry 2015/03/06 21:56:42 Nit: this is inefficient since it copies Source ob
Brian Wilkerson 2015/03/06 23:17:11 Yes it is. But the field is 'final', so making it
Paul Berry 2015/03/09 18:05:33 Fair enough.
+ changeSet.changedSource(source);
+ });
applyChangesToContext(folder, changeSet);
}
break;
« no previous file with comments | « no previous file | pkg/analysis_server/test/context_manager_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698