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

Unified Diff: pkg/dartdoc/lib/dartdoc.dart

Issue 11348036: Alignments for the ClassMirror interface. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments Created 8 years, 2 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 | « no previous file | pkg/dartdoc/lib/mirrors.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/dartdoc/lib/dartdoc.dart
diff --git a/pkg/dartdoc/lib/dartdoc.dart b/pkg/dartdoc/lib/dartdoc.dart
index ad0867d5dc67ed9803f4f26f04b066cde1055847..4b6018cc7aa0e4974faa546c00be4286ea871cf2 100644
--- a/pkg/dartdoc/lib/dartdoc.dart
+++ b/pkg/dartdoc/lib/dartdoc.dart
@@ -604,9 +604,9 @@ class Dartdoc {
typeInfo[MEMBERS] = typeMembers;
}
- if (!type.declaration.typeVariables.isEmpty) {
+ if (!type.originalDeclaration.typeVariables.isEmpty) {
final typeVariables = [];
- for (final typeVariable in type.declaration.typeVariables) {
+ for (final typeVariable in type.originalDeclaration.typeVariables) {
typeVariables.add(typeVariable.displayName);
}
typeInfo[ARGS] = Strings.join(typeVariables, ', ');
@@ -940,15 +940,15 @@ class Dartdoc {
}
listTypes(subtypes, 'Subclasses');
- listTypes(type.interfaces, 'Implements');
+ listTypes(type.superinterfaces, 'Implements');
} else {
// Show the default class.
- if (type.defaultType != null) {
- listTypes([type.defaultType], 'Default class');
+ if (type.defaultFactory != null) {
+ listTypes([type.defaultFactory], 'Default class');
}
// List extended interfaces.
- listTypes(type.interfaces, 'Extends');
+ listTypes(type.superinterfaces, 'Extends');
// List subinterfaces and implementing classes.
final subinterfaces = [];
@@ -1618,7 +1618,7 @@ class Dartdoc {
write(type.simpleName);
}
- if (type.isDeclaration) {
+ if (type.isOriginalDeclaration) {
// Avoid calling [:typeArguments():] on a declaration.
return;
}
@@ -1655,9 +1655,9 @@ class Dartdoc {
assert(type is ClassMirror);
// See if it's a generic type.
- if (type.isDeclaration) {
+ if (type.isOriginalDeclaration) {
final typeParams = [];
- for (final typeParam in type.declaration.typeVariables) {
+ for (final typeParam in type.originalDeclaration.typeVariables) {
if (showBounds &&
(typeParam.bound != null) &&
!typeParam.bound.isObject) {
@@ -1678,7 +1678,7 @@ class Dartdoc {
final typeArgs = type.typeArguments;
if (typeArgs.length > 0) {
final args = Strings.join(typeArgs.map((arg) => typeName(arg)), ', ');
- return '${type.declaration.simpleName}<$args>';
+ return '${type.originalDeclaration.simpleName}<$args>';
}
// Regular type.
« no previous file with comments | « no previous file | pkg/dartdoc/lib/mirrors.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698