EA-100074 - SOE: ExpressionsOfTypeProcessor.containsTypeOrDerivedInside

This commit is contained in:
Dmitry Jemerov
2017-05-11 12:07:05 +02:00
parent ddcde3f688
commit db1f8c7541
@@ -918,7 +918,7 @@ class ExpressionsOfTypeProcessor(
} }
private fun KotlinType.containsTypeOrDerivedInside(type: FuzzyType): Boolean { private fun KotlinType.containsTypeOrDerivedInside(type: FuzzyType): Boolean {
return type.checkIsSuperTypeOf(this) != null || arguments.any { it.type.containsTypeOrDerivedInside(type) } return type.checkIsSuperTypeOf(this) != null || arguments.any { !it.isStarProjection && it.type.containsTypeOrDerivedInside(type) }
} }
private fun isImplicitlyTyped(declaration: KtDeclaration): Boolean { private fun isImplicitlyTyped(declaration: KtDeclaration): Boolean {