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

Unified Diff: pkg/analyzer/lib/src/context/builder.dart

Issue 2206783002: Stress test for comparing analysis performed in two AnalysisContext instances with different option… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 4 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: pkg/analyzer/lib/src/context/builder.dart
diff --git a/pkg/analyzer/lib/src/context/builder.dart b/pkg/analyzer/lib/src/context/builder.dart
index 375535328df656d2b4339d34a4cd7afacd48af35..377e9b1e434f11fd2e01610beba1a9686bbb781e 100644
--- a/pkg/analyzer/lib/src/context/builder.dart
+++ b/pkg/analyzer/lib/src/context/builder.dart
@@ -147,6 +147,9 @@ class ContextBuilder {
Map<String, List<Folder>> folderMap = new HashMap<String, List<Folder>>();
packages.asMap().forEach((String packagePath, Uri uri) {
String path = resourceProvider.pathContext.fromUri(uri);
+ if (path.endsWith(resourceProvider.pathContext.separator)) {
+ path = path.substring(0, path.length - 1);
+ }
folderMap[packagePath] = [resourceProvider.getFolder(path)];
});
return folderMap;
@@ -284,7 +287,7 @@ class ContextBuilder {
return embedderSdk;
});
return dartSdk;
- } else if (extFilePaths != null) {
+ } else if (extFilePaths != null && extFilePaths.isNotEmpty) {
//
// We have an extension file, but no embedder file.
//
« no previous file with comments | « no previous file | pkg/analyzer/test/stress/for_git_repository.dart » ('j') | pkg/analyzer/test/stress/for_git_repository.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698