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

Unified Diff: lib/compiler/implementation/js_backend/emitter.dart

Issue 10915204: Fix bug in dart2js spotted by the change: (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 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 | tests/language/is_interfaces_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/js_backend/emitter.dart
===================================================================
--- lib/compiler/implementation/js_backend/emitter.dart (revision 12208)
+++ lib/compiler/implementation/js_backend/emitter.dart (working copy)
@@ -698,6 +698,16 @@
generateTypeTest(element);
}
generateInterfacesIsTests(element, generateTypeTest, alreadyGenerated);
+
+ // Since [element] is implemented by [cls], we need to also emit
+ // is checks for the superclass and its supertypes.
+ ClassElement superclass = element.superclass;
+ if (!alreadyGenerated.contains(superclass) &&
+ compiler.codegenWorld.checkedClasses.contains(superclass)) {
+ alreadyGenerated.add(superclass);
+ generateTypeTest(superclass);
+ }
+ generateInterfacesIsTests(superclass, generateTypeTest, alreadyGenerated);
}
}
« no previous file with comments | « no previous file | tests/language/is_interfaces_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698