blob: ce31ad2d9f3ea41e95c082e3f18ee06480497d57 [file]
open class A {
fun f(): String =
when (this) {
is B -> x
else -> "FAIL"
}
}
class B(val x: String) : A()
fun box() = B("OK").f()