Minor: fix typo

This commit is contained in:
Mikhail Glukhikh
2024-02-21 11:11:21 +01:00
committed by Space Team
parent 65adbeebd9
commit 16c116908c
2 changed files with 4 additions and 4 deletions
@@ -46,7 +46,7 @@ class FirJavaClass @FirImplementationDetail internal constructor(
override val declarations: MutableList<FirDeclaration>,
override val scopeProvider: FirScopeProvider,
override val symbol: FirRegularClassSymbol,
private val unenhnancedSuperTypes: List<FirTypeRef>,
private val nonEnhancedSuperTypes: List<FirTypeRef>,
override val typeParameters: MutableList<FirTypeParameterRef>,
internal val javaPackage: JavaPackage?,
val javaTypeParameterStack: MutableJavaTypeParameterStack,
@@ -71,7 +71,7 @@ class FirJavaClass @FirImplementationDetail internal constructor(
// TODO: the lazy superTypeRefs is a workaround for KT-55387, some non-lazy solution should probably be used instead
override val superTypeRefs: List<FirTypeRef> by lazy {
val enhancement = FirSignatureEnhancement(this@FirJavaClass, moduleData.session, overridden = { emptyList() })
enhancement.enhanceSuperTypes(unenhnancedSuperTypes)
enhancement.enhanceSuperTypes(nonEnhancedSuperTypes)
}
// TODO: the lazy annotations is a workaround for KT-55387, some non-lazy solution should probably be used instead
@@ -542,11 +542,11 @@ class FirSignatureEnhancement(
).enhance(bound, emptyList(), FirJavaTypeConversionMode.TYPE_PARAMETER_BOUND_AFTER_FIRST_ROUND)
fun enhanceSuperTypes(unenhnancedSuperTypes: List<FirTypeRef>): List<FirTypeRef> {
fun enhanceSuperTypes(nonEnhancedSuperTypes: List<FirTypeRef>): List<FirTypeRef> {
val purelyImplementedSupertype = getPurelyImplementedSupertype(moduleData.session)
val purelyImplementedSupertypeClassId = purelyImplementedSupertype?.classId
return buildList {
unenhnancedSuperTypes.mapNotNullTo(this) { superType ->
nonEnhancedSuperTypes.mapNotNullTo(this) { superType ->
enhanceSuperType(superType).takeUnless {
purelyImplementedSupertypeClassId != null && it.coneType.classId == purelyImplementedSupertypeClassId
}