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

18 lines
288 B
Kotlin

abstract class A {
abstract fun foo(): Any
}
interface B {
fun foo(): String = "B"
}
interface C : A, B
class D : A(), C
fun box(): String {
val d = D()
val r = d.foo() + (d : C).foo() + (d : B).foo() + (d : A).foo()
return if (r == "BBBB") "OK" else "Fail: $r"
}