[FIR] Accept opt-in annotations on primary ctor params of properties

For backward compatibility with K1.

KT-56177
This commit is contained in:
Kirill Rakhman
2023-02-27 17:09:25 +01:00
committed by Space Team
parent cfc5bb74ef
commit fbc0796ed2
7 changed files with 61 additions and 4 deletions
@@ -0,0 +1,15 @@
// SKIP_TXT
// FIR_IDENTICAL
@RequiresOptIn(level = RequiresOptIn.Level.ERROR)
annotation class E
abstract class Foo {
@E
abstract val bar: String
}
class SubFoo(
@OptIn(E::class)
override val bar: String,
) : Foo()