Files
kotlin/compiler/testData/codegen/box/reflection/functions/functionFromStdlib.kt
Ilya Gorbunov 7573fcde53 Demote new experimental capitalize overloads in overload resolution
Revert "Fix method reference ambiguity in test after introducing 'capitalize' overload"
This reverts commit fe9bd9ee
2019-07-09 03:39:25 +03:00

12 lines
265 B
Kotlin
Vendored

// TARGET_BACKEND: JVM
// WITH_REFLECT
import kotlin.reflect.KFunction1
import kotlin.reflect.jvm.isAccessible
fun doStuff(fn: KFunction1<String, String>) = fn.call("oK")
fun box(): String {
return doStuff(String::capitalize.apply { isAccessible = true })
}