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

Unified Diff: tools/dom/docs/lib/docs.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
« no previous file with comments | « tests/utils/source_mirrors_test.dart ('k') | utils/apidoc/apidoc.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/docs/lib/docs.dart
diff --git a/tools/dom/docs/lib/docs.dart b/tools/dom/docs/lib/docs.dart
index e7c4abfa9c4015182731235acef19a581cccfe9d..62ca83642f66e6e928b7016ef0fb1d7c3ae960f2 100644
--- a/tools/dom/docs/lib/docs.dart
+++ b/tools/dom/docs/lib/docs.dart
@@ -11,7 +11,7 @@
library docs;
import '../../../../sdk/lib/_internal/dartdoc/lib/src/dart2js_mirrors.dart';
-import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/mirrors.dart';
+import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/source_mirrors.dart';
import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/mirrors_util.dart';
import '../../../../sdk/lib/_internal/dartdoc/lib/dartdoc.dart';
import '../../../../sdk/lib/_internal/dartdoc/lib/src/json_serializer.dart';
@@ -93,15 +93,17 @@ Map _generateJsonFromLibraries(MirrorSystem mirrors) {
var libraryJson = {};
var sortedClasses = _sortAndFilterMirrors(
- libMirror.classes.values.toList(), ignoreDocsEditable: true);
+ classesOf(libMirror.declarations).toList(), ignoreDocsEditable: true);
for (ClassMirror classMirror in sortedClasses) {
+ print(' class: $classMirror');
var classJson = {};
var sortedMembers = _sortAndFilterMirrors(
- classMirror.members.values.toList());
+ membersOf(classMirror.declarations).toList());
var membersJson = {};
for (var memberMirror in sortedMembers) {
+ print(' member: $memberMirror');
var memberDomName = domNames(memberMirror)[0];
var memberComment = _splitCommentsByNewline(
computeUntrimmedCommentAsList(memberMirror));
@@ -136,7 +138,7 @@ Map _generateJsonFromLibraries(MirrorSystem mirrors) {
}
if (!libraryJson.isEmpty) {
- convertedJson.putIfAbsent(libMirror.simpleName, () =>
+ convertedJson.putIfAbsent(nameOf(libMirror), () =>
libraryJson);
}
}
@@ -182,7 +184,7 @@ List<String> domNames(DeclarationMirror mirror) {
if (domNameMetadata != null) {
var domNames = <String>[];
- var tags = domNameMetadata.getField('name');
+ var tags = domNameMetadata.getField(#name);
for (var s in tags.reflectee.split(',')) {
domNames.add(s.trim());
}
« no previous file with comments | « tests/utils/source_mirrors_test.dart ('k') | utils/apidoc/apidoc.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698