mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
15 lines
253 B
Kotlin
15 lines
253 B
Kotlin
// PROBLEM: none
|
|
// WITH_STDLIB
|
|
// COMPILER_ARGUMENTS: -Xopt-in=kotlin.RequiresOptIn
|
|
|
|
@RequiresOptIn
|
|
annotation class Marker
|
|
|
|
@Marker
|
|
inline fun <reified T> foo(x: Any): T? = x as? T
|
|
|
|
@OptIn(Marker::class<caret>)
|
|
fun bar() {
|
|
val y: Int? = foo(14)
|
|
}
|