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

Unified Diff: lib/compiler/implementation/namer.dart

Issue 10834387: Stop keeping track of the which library use which private selectors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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: lib/compiler/implementation/namer.dart
diff --git a/lib/compiler/implementation/namer.dart b/lib/compiler/implementation/namer.dart
index fc43d2fa4769c638aa0247219b969aa64655b66d..05994920eeadec6afae32f47a9436c43e854040e 100644
--- a/lib/compiler/implementation/namer.dart
+++ b/lib/compiler/implementation/namer.dart
@@ -20,13 +20,11 @@ class Namer {
Map<Element, String> globals;
Map<String, int> usedGlobals;
- Map<String, Set<LibraryElement>> usedPrivateNames;
Map<String, LibraryElement> shortPrivateNameOwners;
Namer(this.compiler)
: globals = new Map<Element, String>(),
usedGlobals = new Map<String, int>(),
- usedPrivateNames = new Map<String, Set<LibraryElement>>(),
shortPrivateNameOwners = new Map<String, LibraryElement>();
final String CURRENT_ISOLATE = @'$';
@@ -98,14 +96,6 @@ class Namer {
String privateName(LibraryElement lib, SourceString name) {
if (name.isPrivate()) {
String nameString = name.slowToString();
-
- // TODO(kasperl): This is a bit of a hacky way of keeping track
- // of the libraries that use a particular private name.
- Set<LibraryElement> usedBy =
- usedPrivateNames.putIfAbsent(nameString, () =>
- new Set<LibraryElement>());
- usedBy.add(lib);
-
// The first library asking for a short private name wins.
LibraryElement owner =
shortPrivateNameOwners.putIfAbsent(nameString, () => lib);

Powered by Google App Engine
This is Rietveld 408576698