Fixed new/old type inference diff, sometimes causes problems in JPS

This commit is contained in:
Alexander Podkhalyuzin
2019-10-30 18:05:34 +03:00
parent 607249e899
commit aa604d0854
@@ -134,7 +134,10 @@ class FirSamResolverImpl(
for ((newTypeParameter, oldTypeParameter) in newTypeParameters.zip(firRegularClass.typeParameters)) {
newTypeParameter.bounds += oldTypeParameter.bounds.mapNotNull { typeRef ->
FirResolvedTypeRefImpl(typeRef.source, substitutor.substituteOrSelf(typeRef.coneTypeSafe() ?: return@mapNotNull null))
FirResolvedTypeRefImpl(
typeRef.source,
substitutor.substituteOrSelf(typeRef.coneTypeSafe<ConeKotlinType>() ?: return@mapNotNull null)
)
}
}