[FIR2IR] Approximate non-denotable types when converting ConeType to IrType
This commit is contained in:
committed by
TeamCityServer
parent
c271f953d7
commit
da0fd7cc15
@@ -485,7 +485,11 @@ interface ConeInferenceContext : TypeSystemInferenceExtensionContext, ConeTypeCo
|
||||
firstCandidate: KotlinTypeMarker,
|
||||
secondCandidate: KotlinTypeMarker
|
||||
): KotlinTypeMarker {
|
||||
// TODO
|
||||
return firstCandidate
|
||||
require(firstCandidate is ConeKotlinType)
|
||||
require(secondCandidate is ConeKotlinType)
|
||||
val intersectionType = firstCandidate.lowerBoundIfFlexible() as? ConeIntersectionType ?: error {
|
||||
"Expected type is intersection, found $firstCandidate"
|
||||
}
|
||||
return intersectionType.withAlternative(secondCandidate)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user