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

Unified Diff: sdk/lib/_internal/dartdoc/lib/src/dartdoc/utils.dart

Issue 119913002: Align source mirrors with runtime mirrors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments + small fix. Created 6 years, 11 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: sdk/lib/_internal/dartdoc/lib/src/dartdoc/utils.dart
diff --git a/sdk/lib/_internal/dartdoc/lib/src/dartdoc/utils.dart b/sdk/lib/_internal/dartdoc/lib/src/dartdoc/utils.dart
index 3f876b6e81788af2d84040beab3f4e5e09fb617e..b25642435e53083f94ac227c9735c8e19b0a399c 100644
--- a/sdk/lib/_internal/dartdoc/lib/src/dartdoc/utils.dart
+++ b/sdk/lib/_internal/dartdoc/lib/src/dartdoc/utils.dart
@@ -10,7 +10,7 @@ import 'dart:math' as math;
import 'package:path/path.dart' as pathos;
-import '../../../../compiler/implementation/mirrors/mirrors.dart';
+import '../../../../compiler/implementation/mirrors/source_mirrors.dart';
import '../export_map.dart';
@@ -57,11 +57,11 @@ String unindent(String text, int indentation) {
}
/** Sorts the map by the key, doing a case-insensitive comparison. */
-List<Mirror> orderByName(Iterable<Mirror> list) {
+List<Mirror> orderByName(Iterable<DeclarationMirror> list) {
final elements = new List<Mirror>.from(list);
elements.sort((a,b) {
- String aName = a.simpleName.toLowerCase();
- String bName = b.simpleName.toLowerCase();
+ String aName = MirrorSystem.getName(a.simpleName).toLowerCase();
+ String bName = MirrorSystem.getName(b.simpleName).toLowerCase();
bool doma = aName.startsWith(r"$dom");
bool domb = bName.startsWith(r"$dom");
return doma == domb ? aName.compareTo(bName) : doma ? 1 : -1;
« no previous file with comments | « sdk/lib/_internal/dartdoc/lib/src/dart2js_mirrors.dart ('k') | sdk/lib/_internal/dartdoc/lib/src/export_map.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698