[NI] Fix extracting type variables for flexible types in in captured types
Bug was introduced in b99efb because of lack of tests. All code in `AbstractTypeCheckerContextForConstraintSystem.extractTypeVariableForSubtype` related to IN projection looks suspicious and needs further investigation
This commit is contained in:
+1
-1
@@ -90,7 +90,7 @@ abstract class AbstractTypeCheckerContextForConstraintSystem : AbstractTypeCheck
|
||||
val projection = typeMarker.typeConstructorProjection()
|
||||
if (projection.isStarProjection()) return null
|
||||
if (projection.getVariance() == TypeVariance.IN) {
|
||||
val type = projection.getType().let { it.asSimpleType() ?: it.asFlexibleType()?.lowerBound() } ?: return null
|
||||
val type = projection.getType().asSimpleType() ?: return null
|
||||
if (isMyTypeVariable(type)) {
|
||||
simplifyLowerConstraint(type, superType)
|
||||
if (isMyTypeVariable(superType.asSimpleType() ?: return null)) {
|
||||
|
||||
Reference in New Issue
Block a user