diff --git a/plugins/allopen/allopen.k2/src/org/jetbrains/kotlin/allopen/fir/FirAllOpenStatusTransformer.kt b/plugins/allopen/allopen.k2/src/org/jetbrains/kotlin/allopen/fir/FirAllOpenStatusTransformer.kt index c90e8151ffe..8a308c55139 100644 --- a/plugins/allopen/allopen.k2/src/org/jetbrains/kotlin/allopen/fir/FirAllOpenStatusTransformer.kt +++ b/plugins/allopen/allopen.k2/src/org/jetbrains/kotlin/allopen/fir/FirAllOpenStatusTransformer.kt @@ -30,7 +30,7 @@ class FirAllOpenStatusTransformer(session: FirSession) : FirStatusTransformerExt if (parentClassId.isLocal) return false val parentClassSymbol = session.symbolProvider.getClassLikeSymbolByClassId(parentClassId) as? FirRegularClassSymbol ?: return false - session.allOpenPredicateMatcher.isAnnotated(parentClassSymbol) + parentClassSymbol.classKind == ClassKind.CLASS && session.allOpenPredicateMatcher.isAnnotated(parentClassSymbol) } else -> false } diff --git a/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.fir.kt b/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.fir.kt deleted file mode 100644 index 863810dfd08..00000000000 --- a/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.fir.kt +++ /dev/null @@ -1,9 +0,0 @@ -// WITH_STDLIB -// ISSUE: KT-63507 - -annotation class AllOpen - -@AllOpen -annotation class SubComponent( - val scope: String -) diff --git a/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.kt b/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.kt index 3e48ce69633..36e54e846dd 100644 --- a/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.kt +++ b/plugins/allopen/testData/diagnostics/allOpenOnAnnotation.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // WITH_STDLIB // ISSUE: KT-63507 diff --git a/plugins/allopen/testData/diagnostics/kt54260.fir.kt b/plugins/allopen/testData/diagnostics/kt54260.fir.kt deleted file mode 100644 index 36a668f0233..00000000000 --- a/plugins/allopen/testData/diagnostics/kt54260.fir.kt +++ /dev/null @@ -1,9 +0,0 @@ -// WITH_STDLIB - -annotation class AllOpen - -@AllOpen -annotation class ConsoleCommands( - val value: String = "", - val scope: String -) diff --git a/plugins/allopen/testData/diagnostics/kt54260.kt b/plugins/allopen/testData/diagnostics/kt54260.kt index f24494383b2..5886b799d5c 100644 --- a/plugins/allopen/testData/diagnostics/kt54260.kt +++ b/plugins/allopen/testData/diagnostics/kt54260.kt @@ -1,3 +1,4 @@ +// FIR_IDENTICAL // WITH_STDLIB annotation class AllOpen