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

Unified Diff: dart/lib/compiler/implementation/enqueue.dart

Issue 10836235: Check overrides. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 4 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: dart/lib/compiler/implementation/enqueue.dart
diff --git a/dart/lib/compiler/implementation/enqueue.dart b/dart/lib/compiler/implementation/enqueue.dart
index a42b1d4e2dcd36f1570daadb293616b2f7d50d37..bfa2636d272df72bdb289b04f1ec3143a432eb02 100644
--- a/dart/lib/compiler/implementation/enqueue.dart
+++ b/dart/lib/compiler/implementation/enqueue.dart
@@ -214,12 +214,19 @@ class Enqueuer {
void onRegisterInstantiatedClass(ClassElement cls) {
task.measure(() {
- while (cls !== null) {
- if (seenClasses.contains(cls)) return;
+ cls.ensureResolved(compiler); // So allSupertypesAndSelf works.
karlklose 2012/08/14 11:06:51 How about something like 'Compute set of all super
ahe 2012/08/14 18:20:34 Done.
+ for (Link<Type> supertypes = cls.allSupertypesAndSelf;
+ !supertypes.isEmpty(); supertypes = supertypes.tail) {
+ cls = supertypes.head.element;
+ if (seenClasses.contains(cls)) continue;
seenClasses.add(cls);
cls.ensureResolved(compiler);
- cls.members.forEach(processInstantiatedClassMember);
- cls = cls.superclass;
+ if (!cls.isInterface()) {
+ cls.members.forEach(processInstantiatedClassMember);
+ }
+ if (isResolutionQueue) {
+ compiler.resolver.checkMembers(cls);
+ }
}
});
}

Powered by Google App Engine
This is Rietveld 408576698