Files
kotlin-fork/compiler/testData/debug/stepping/inlineSimpleCall.kt
T
pyos c43acba0b9 JVM: restore call site line number after inlining lambda
E.g. in `x + f()` where `f` is an inline lambda, the instructions for
`+` should have the line number of that expression (while previously
they instead had the line number of the last line of the lambda).

^KT-51738 Fixed
2022-05-02 19:28:10 +02:00

51 lines
679 B
Kotlin
Vendored

// FILE: test.kt
inline fun inlineFun(s: () -> Unit) {
s()
}
fun box() {
inlineFun ({
1
})
inlineFun {
2
}
inlineFun {
3
inlineFun {
4
}
}
}
// EXPECTATIONS
// test.kt:8 box
// test.kt:4 box
// test.kt:9 box
// test.kt:10 box
// test.kt:4 box
// test.kt:5 box
// test.kt:12 box
// test.kt:4 box
// test.kt:13 box
// test.kt:14 box
// test.kt:4 box
// test.kt:5 box
// test.kt:16 box
// test.kt:4 box
// test.kt:17 box
// test.kt:19 box
// test.kt:4 box
// test.kt:20 box
// test.kt:21 box
// test.kt:4 box
// test.kt:5 box
// test.kt:22 box
// test.kt:4 box
// test.kt:5 box
// test.kt:23 box