Index: pkg/compiler/lib/src/elements/common.dart |
diff --git a/pkg/compiler/lib/src/elements/common.dart b/pkg/compiler/lib/src/elements/common.dart |
index 9d0458229d63dbeddfc38b4cb521c2d630306382..f9c4e59201d82ebf3b347d49a57da339f3e362c6 100644 |
--- a/pkg/compiler/lib/src/elements/common.dart |
+++ b/pkg/compiler/lib/src/elements/common.dart |
@@ -406,13 +406,8 @@ abstract class ClassElementCommon implements ClassElement { |
@override |
bool implementsInterface(ClassElement intrface) { |
- for (DartType implementedInterfaceType in allSupertypes) { |
- ClassElement implementedInterface = implementedInterfaceType.element; |
- if (identical(implementedInterface, intrface)) { |
- return true; |
- } |
- } |
- return false; |
+ return this != intrface && |
+ allSupertypesAndSelf.asInstanceOf(intrface) != null; |
Johnni Winther
2015/10/13 10:14:55
Optimization
|
} |
@override |