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

Unified Diff: pkg/analyzer/lib/src/summary/prelink.dart

Issue 2678273007: When a name is both exported and defined locally, the name is defined. (Closed)
Patch Set: Created 3 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/test/src/summary/resynthesize_common.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/summary/prelink.dart
diff --git a/pkg/analyzer/lib/src/summary/prelink.dart b/pkg/analyzer/lib/src/summary/prelink.dart
index 31fa6a5fe098ee1cab431e4752e2bb8ad40d467b..6005808e3826592d8598d8f57b69d2939b0ba343 100644
--- a/pkg/analyzer/lib/src/summary/prelink.dart
+++ b/pkg/analyzer/lib/src/summary/prelink.dart
@@ -284,6 +284,8 @@ class _Prelinker {
}
}
+ aggregated.rememberLibraryNames();
+
dependencyToPublicNamespace.add(aggregated);
return aggregated;
}
@@ -314,7 +316,8 @@ class _Prelinker {
new NameFilter.forUnlinkedCombinators(export.combinators));
aggregatePublicNamespace(exportUri)
.forEach((String name, _Meaning meaning) {
- if (newFilter.accepts(name)) {
+ if (newFilter.accepts(name) &&
+ !exportNamespace.definesLibraryName(name)) {
exportNamespace.add(name, meaning);
}
});
« no previous file with comments | « no previous file | pkg/analyzer/test/src/summary/resynthesize_common.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698