Files
kotlin/compiler/testData/codegen/bytecodeText/lineNumbers/stdlibInlineOnly.kt
pyos deecb6a28e JVM: move synthetic line number generation to the inliner
This makes the behavior of JVM and JVM_IR the same without having to
deal with PSI nodes.
2020-04-28 17:21:07 +02:00

16 lines
385 B
Kotlin
Vendored

@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
@kotlin.internal.InlineOnly
inline fun <T, R> T.myLet(block: (T) -> R) = block(this)
fun box(): String {
val k = "".myLet {
it + "K"
}
return "O".myLet(fun (it: String): String {
return it + k
})
}
// See KT-23064 for the problem and InlineOnlySmapSkipper for an explanation.
// 0 LINENUMBER 65100