[FIR] Add missing type-alias unwrap in CompletionModeCalculator

This commit is contained in:
Simon Ogorodnik
2021-07-28 13:08:46 +03:00
committed by Mikhail Glukhikh
parent 8e890eba3e
commit ed07e1c778
@@ -125,11 +125,12 @@ private class CalculatorForNestedCall(
type: KotlinTypeMarker, outerVariance: TypeVariance,
fixationDirectionsCollector: MutableSet<FixationDirectionForVariable>
) {
val typeArgumentsCount = type.argumentsCount()
val unwrappedType = type.lowerBoundIfFlexible()
val typeArgumentsCount = unwrappedType.argumentsCount()
if (typeArgumentsCount > 0) {
for (position in 0 until typeArgumentsCount) {
val argument = type.getArgument(position)
val parameter = type.typeConstructor().getParameter(position)
val argument = unwrappedType.getArgument(position)
val parameter = unwrappedType.typeConstructor().getParameter(position)
if (argument.isStarProjection())
continue