We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1391397 commit 0c5ed8bCopy full SHA for 0c5ed8b
compiler/fir/resolve/src/org/jetbrains/kotlin/fir/resolve/transformers/FirSupertypesResolution.kt
@@ -451,7 +451,7 @@ open class FirSupertypeResolverVisitor(
451
private fun addSelfToTypeParameters(firClass: FirClassLikeDeclaration, session: FirSession) {
452
val isSelf = firClass.getAnnotationByClassId(StandardClassIds.Annotations.Self, session) != null
453
val params = firClass.typeParameters
454
- if (params is MutableList && isSelf) {
+ if (params is MutableList && isSelf && params.find { it.symbol.name == SpecialNames.SELF_TYPE } == null) {
455
val selfSymbol = FirTypeParameterSymbol()
456
val firTypeParameterBuilder = FirTypeParameterBuilder()
457
firTypeParameterBuilder.bounds.add(buildResolvedTypeRef {
0 commit comments