Files
kotlin-fork/compiler/testData/diagnostics/tests/resolve/nestedCalls/kt5971NestedSafeCall.fir.kt
T
simon.ogorodnik 34e6649d31 [FIR] Harden check of argument type properly
Before this commit, nullable argument could match not null parameter.
Now we require also correct nullability that breaks some cases
2020-02-03 16:45:18 +03:00

10 lines
185 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_PARAMETER
//KT-5971 Missing error when fun argument is safe call
fun foo(i: Int) {}
fun test(s: String?) {
<!INAPPLICABLE_CANDIDATE!>foo<!>(s?.length)
}