f283f2db43
Also introduce few new diagnostics: - NONE_APPLICABLE more many inapplicable candidates - HIDDEN for visible candidates
14 lines
309 B
Kotlin
Vendored
14 lines
309 B
Kotlin
Vendored
// See KT-10056
|
|
class Foo(val bar: String)
|
|
|
|
fun test(foo: Foo?) {
|
|
foo?.bar.let {
|
|
// Error, foo?.bar is nullable
|
|
it.<!INAPPLICABLE_CANDIDATE!>length<!>
|
|
// Error, foo is nullable
|
|
foo.<!INAPPLICABLE_CANDIDATE!>bar<!>.length
|
|
// Correct
|
|
foo?.bar?.length
|
|
}
|
|
}
|