Files
kotlin-fork/compiler/testData/codegen/box/bridges/traitImplInheritsTraitImpl.kt
T
2015-05-12 19:43:17 +02:00

16 lines
251 B
Kotlin
Vendored

interface A {
fun foo(): Any = "A"
}
interface B : A {
override fun foo(): String = "B"
}
class C : B
fun box(): String {
val c = C()
var r = c.foo() + (c : B).foo() + (c : A).foo()
return if (r == "BBB") "OK" else "Fail: $r"
}