Files
kotlin-fork/compiler/testData/codegen/boxInline/smap/anonymous/objectOnInlineCallSite2.kt
T
Ilya Chernikov 5b3816cce5 Test infra: refactor IGNORE_BACKEND directive
treat it as a general one, introduce *_K1 and *_K2 variants for
more specific ignoring
2022-11-12 16:28:23 +01:00

36 lines
585 B
Kotlin
Vendored

// IGNORE
// NO_CHECK_LAMBDA_INLINING
// IGNORE_BACKEND_MULTI_MODULE: JVM, JVM_IR, JVM_MULTI_MODULE_OLD_AGAINST_IR, JVM_MULTI_MODULE_IR_AGAINST_OLD
// IGNORE_BACKEND_K2_MULTI_MODULE: JVM_IR JVM_IR_SERIALIZE
// FILE: 1.kt
// NO_SMAP_DUMP
package builders
inline fun call(crossinline init: () -> Unit) {
return init()
}
inline fun test(): String {
var res = "Fail"
call {
object {
fun run () {
res = "OK"
}
}.run()
}
return res
}
// FILE: 2.kt
import builders.*
fun box(): String {
return test()
}