Files
kotlin-fork/compiler/testData/ir/irText/firProblems/OutBox.kt
T
2023-06-09 08:22:21 +00:00

27 lines
441 B
Kotlin
Vendored

// TARGET_BACKEND: JVM
// FILE: Foo.java
public class Foo {
public abstract static class Bar extends Foo {
}
public static class Buz extends Bar {
public String str = "OK";
}
}
// FILE: Box.kt
class Box<out T : Foo>(val foo: T) {
val str: String
get() {
var foo: Foo = foo
if (foo is Foo.Buz) {
return foo.str
}
return "";
}
}