22e26d0756
* Also cleanup tests to avoid using obsolete WITH_RUNTIME
35 lines
463 B
Kotlin
Vendored
35 lines
463 B
Kotlin
Vendored
// TARGET_BACKEND: JVM_IR
|
|
// NO_CHECK_LAMBDA_INLINING
|
|
|
|
// WITH_STDLIB
|
|
|
|
// MODULE: lib
|
|
// FILE: MyEnum.kt
|
|
|
|
package test
|
|
|
|
enum class X {
|
|
O,
|
|
K
|
|
}
|
|
|
|
inline fun test(block: () -> String): String {
|
|
return block()
|
|
}
|
|
|
|
// MODULE: caller(lib)
|
|
// !LANGUAGE: +EnumEntries
|
|
|
|
// FILE: 2.kt
|
|
|
|
import test.*
|
|
|
|
@OptIn(ExperimentalStdlibApi::class)
|
|
fun box(): String {
|
|
return test {
|
|
X.entries[0].toString()
|
|
} + test {
|
|
X.entries[1].toString()
|
|
}
|
|
}
|