Files
kotlin-fork/compiler/testData/codegen/boxWithStdlib/reflection/callBy/simpleMemberFunciton.kt
T
Alexander Udalov 593937d302 Support KCallable.callBy with map of parameters to arguments
callBy is able to handle optional parameters.

 #KT-8827 Fixed
2015-08-29 18:37:40 +03:00

9 lines
208 B
Kotlin
Vendored

class A(val result: String = "OK") {
fun foo(x: Int = 42): String {
assert(x == 42) { x }
return result
}
}
fun box(): String = A::foo.callBy(mapOf(A::foo.parameters.first() to A()))