mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-17 08:31:29 +00:00
16 lines
386 B
Kotlin
Vendored
16 lines
386 B
Kotlin
Vendored
import test.*
|
|
|
|
fun box(): String {
|
|
val res = test {
|
|
"OK"
|
|
}
|
|
|
|
val enclosingMethod = res.javaClass.enclosingMethod
|
|
if (enclosingMethod?.name != "box") return "fail 1: ${enclosingMethod?.name}"
|
|
|
|
val enclosingClass = res.javaClass.enclosingClass
|
|
if (enclosingClass?.name != "ObjectInInlineFun_1Kt") return "fail 2: ${enclosingClass?.name}"
|
|
|
|
return "OK"
|
|
}
|