Index: pkg/front_end/lib/src/fasta/builder/library_builder.dart |
diff --git a/pkg/front_end/lib/src/fasta/builder/library_builder.dart b/pkg/front_end/lib/src/fasta/builder/library_builder.dart |
index e3067aa8ccbf980457e61dbfc39343eb82734d3b..ec866a9ee1e4a64e0076b2ba39ffea07ffb29729 100644 |
--- a/pkg/front_end/lib/src/fasta/builder/library_builder.dart |
+++ b/pkg/front_end/lib/src/fasta/builder/library_builder.dart |
@@ -98,6 +98,11 @@ abstract class LibraryBuilder<T extends TypeBuilder, R> extends Builder { |
Builder existing = map[name]; |
if (existing == member) return false; |
if (existing != null) { |
+ // For each entry mapping key `k` to declaration `d` in `NS` an entry |
+ // mapping `k` to `d` is added to the exported namespace of `L` unless a |
+ // top-level declaration with the name `k` exists in `L`. |
+ if (existing.parent == this) return false; |
ahe
2017/05/22 11:39:45
buildAmbiguousBuilder should take care of this.
scheglov
2017/05/22 18:35:24
Ah, I see now.
https://codereview.chromium.org/289
|
+ |
Builder result = |
buildAmbiguousBuilder(name, existing, member, -1, isExport: true); |
map[name] = result; |