K2: reproduce strange "smartcast aside" behavior related to KT-62544 fix
This commit is contained in:
committed by
Space Team
parent
9c146adc3a
commit
1ef0f9e944
@@ -0,0 +1,19 @@
|
||||
interface A {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
interface B : A {
|
||||
fun bar()
|
||||
}
|
||||
|
||||
interface C : A {
|
||||
fun baz()
|
||||
}
|
||||
|
||||
fun test(param: B) {
|
||||
if (param is C) {
|
||||
param.foo()
|
||||
param.bar()
|
||||
param.baz()
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user