Files
kotlin-fork/compiler/testData/codegen/box/reflection/call/fakeOverride.kt
T
2016-11-09 21:41:12 +03:00

16 lines
283 B
Kotlin
Vendored

// TODO: muted automatically, investigate should it be ran for JS or not
// IGNORE_BACKEND: JS
// WITH_REFLECT
open class A {
fun foo() = "OK"
}
class B : A()
fun box(): String {
val foo = B::class.members.single { it.name == "foo" }
return foo.call(B()) as String
}