Files
kotlin/compiler/testData/codegen/box/classes/kt1976.kt
2015-01-13 15:02:16 +03:00

9 lines
195 B
Kotlin
Vendored

class A {
public val f : ()->String = {"OK"}
}
fun box(): String {
val a = A()
return a.f() // does not work: (in runtime) ClassCastException: A cannot be cast to kotlin.Function0
}