mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-17 00:21:28 +00:00
16 lines
233 B
Kotlin
Vendored
16 lines
233 B
Kotlin
Vendored
// KT-338 Support.smartcasts in nested declarations
|
|
|
|
fun f(a: Any?) {
|
|
if (a is B) {
|
|
class C : X(a) {
|
|
init {
|
|
a.<!UNRESOLVED_REFERENCE!>foo<!>()
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
interface B {
|
|
fun foo() {}
|
|
}
|
|
open class X(b: B) |