IR: Fix StackOverflowError caused by using DNN type in lambda
^KT-54140 Fixed
This commit is contained in:
committed by
Space Team
parent
c586d7a03a
commit
6d7096b5e9
@@ -1150,7 +1150,9 @@ fun IrType.toIrBasedKotlinType(): KotlinType = when (this) {
|
||||
is IrSimpleType ->
|
||||
makeKotlinType(classifier, arguments, isMarkedNullable()).let {
|
||||
if (classifier is IrTypeParameterSymbol && nullability == SimpleTypeNullability.DEFINITELY_NOT_NULL) {
|
||||
DefinitelyNotNullType.makeDefinitelyNotNull(it.unwrap()) ?: it
|
||||
// avoidCheckingActualTypeNullability = true is necessary because in recursive cases `makesSenseToBeDefinitelyNotNull` triggers
|
||||
// supertype computation for a type parameter and for which bounds we need to call `toIrBasedKotlinType` again
|
||||
DefinitelyNotNullType.makeDefinitelyNotNull(it.unwrap(), avoidCheckingActualTypeNullability = true) ?: it
|
||||
} else {
|
||||
it
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user