Files
kotlin-fork/compiler/testData/diagnostics/testsWithStdLib/experimental/errors.fir.kt
T
2021-06-08 11:37:27 +03:00

28 lines
333 B
Kotlin
Vendored

// !USE_EXPERIMENTAL: kotlin.RequiresOptIn
// FILE: api.kt
package api
@RequiresOptIn
@Retention(AnnotationRetention.BINARY)
annotation class E
open class Base {
@E
open fun foo() {}
}
// FILE: usage.kt
package usage
import api.*
class Derived : Base() {
override fun foo() {}
}
fun test(b: Base) {
b.foo()
}