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

Unified Diff: tools/dom/src/native_DOMImplementation.dart

Issue 63483002: Fix some users of removed mirror API. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 1 month 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 | « sdk/lib/_internal/dartdoc/lib/universe_serializer.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/src/native_DOMImplementation.dart
diff --git a/tools/dom/src/native_DOMImplementation.dart b/tools/dom/src/native_DOMImplementation.dart
index 43d542f8fe68b569add11d691992f67016feca1e..f24c81a9c589a8e0be28cb47834f273bb250d043 100644
--- a/tools/dom/src/native_DOMImplementation.dart
+++ b/tools/dom/src/native_DOMImplementation.dart
@@ -302,7 +302,7 @@ class _Utils {
addForClass(ClassMirror mirror, bool isStatic) {
if (mirror == null)
return;
- addAll(mirror.members, isStatic);
+ addAll(mirror.declarations, isStatic);
if (mirror.superclass != null)
addForClass(mirror.superclass, isStatic);
for (var interface in mirror.superinterfaces) {
@@ -422,8 +422,10 @@ class _Utils {
throw new UnsupportedError("Invalid custom element from $libName.");
}
var className = MirrorSystem.getName(cls.simpleName);
- var createdConstructor = cls.constructors[new Symbol('$className.created')];
- if (createdConstructor == null) {
+ var createdConstructor = cls.declarations[new Symbol('$className.created')];
+ if (createdConstructor == null ||
+ createdConstructor is! MethodMirror ||
+ !createdConstructor.isConstructor) {
throw new UnsupportedError(
'Class is missing constructor $className.created');
}
« no previous file with comments | « sdk/lib/_internal/dartdoc/lib/universe_serializer.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698