12 lines
149 B
Plaintext
Vendored
12 lines
149 B
Plaintext
Vendored
interface T {
|
|
fun foo(): Int
|
|
}
|
|
|
|
interface U: T
|
|
|
|
fun test(t: T): Int {
|
|
val foo = t.foo()
|
|
return if (t is U)
|
|
foo + 1
|
|
else foo
|
|
} |