Files
kotlin-fork/compiler/testData/diagnostics/tests/nullabilityAndSmartCasts/unstableSmartcastWithOverloadedExtensions.fir.kt
T
Dmitriy Novozhilov 6735cc8937 [FIR] Implement new bound smartcast algorithm
#KT-36055 Fixed
2020-02-12 10:17:45 +03:00

14 lines
217 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_PARAMETER
class A
class B
fun A.foo(a: A) {}
fun A.foo(b: B) {}
var a: A? = null
fun smartCastInterference(b: B) {
if (a != null) {
a.<!INAPPLICABLE_CANDIDATE!>foo<!>(b)
}
}