[FIR2IR] Properly insert implicit casts to extension receiver in case of intersection smartcast type
^KT-62863 Fixed
This commit is contained in:
committed by
Space Team
parent
50106c740c
commit
420fbad73d
+18
@@ -0,0 +1,18 @@
|
||||
fun <F : CharSequence> F.bar() {
|
||||
}
|
||||
|
||||
inline fun <reified T : CharSequence> test_1(x: Any) {
|
||||
when {
|
||||
x is T -> { // BLOCK
|
||||
x /*as T */.bar<T>()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun test_2(x: Any?) {
|
||||
when {
|
||||
x is CharSequence -> { // BLOCK
|
||||
x /*as CharSequence */.bar<CharSequence>()
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user