Index: pkg/compiler/lib/src/js_emitter/lazy_emitter/model_emitter.dart |
diff --git a/pkg/compiler/lib/src/js_emitter/lazy_emitter/model_emitter.dart b/pkg/compiler/lib/src/js_emitter/lazy_emitter/model_emitter.dart |
index 96838acd777085862c3102e24640a8cd5e9b6da4..485195ee92768c3d71cfb130ca70d760b05f4239 100644 |
--- a/pkg/compiler/lib/src/js_emitter/lazy_emitter/model_emitter.dart |
+++ b/pkg/compiler/lib/src/js_emitter/lazy_emitter/model_emitter.dart |
@@ -21,7 +21,6 @@ import '../../js_backend/js_backend.dart' show |
ConstantEmitter; |
import '../js_emitter.dart' show NativeEmitter; |
-import '../constant_ordering.dart' show deepCompareConstants; |
import 'package:js_runtime/shared/embedded_names.dart' show |
CREATE_NEW_ISOLATE, |
@@ -109,9 +108,9 @@ class ModelEmitter { |
// which compresses a tiny bit better. |
int r = namer.constantLongName(a).compareTo(namer.constantLongName(b)); |
if (r != 0) return r; |
- |
- // Resolve collisions in the long name by using a structural order. |
- return deepCompareConstants(a, b); |
+ // Resolve collisions in the long name by using the constant name (i.e. JS |
+ // name) which is unique. |
+ return namer.constantName(a).compareTo(namer.constantName(b)); |
} |
js.Expression generateStaticClosureAccess(FunctionElement element) { |