Files
kotlin-fork/compiler/testData/codegen/box/callableReference/arrayConstructor.kt
T
vladislav.grechko e5763a692f Substitute type arguments to return type of inlined function references
Such substitution is crucial on codegen stage if the return type is
reified (e.g. for `Array`)

^KT-59507: Fixed
^KT-59281: Fixed
2023-07-24 22:11:59 +00:00

10 lines
243 B
Kotlin
Vendored

// WITH_STDLIB
fun g(b: (Int, (Int) -> String) -> Array<String>): Array<String> =
b(1) { "O" }
inline fun h(b: (Int, (Int) -> String) -> Array<String>): Array<String> =
b(1) { "K" }
fun box(): String = g(::Array)[0] + h(::Array)[0]