6a03f31e50
Previously unsafe call is reported as part of InapplicableWrongReceiver. This makes it difficult for the downstream checkers to report different diagnostics.
14 lines
198 B
Kotlin
Vendored
14 lines
198 B
Kotlin
Vendored
fun <T : Any?> foo(x: T) {
|
|
if (x is String?) {
|
|
x<!UNSAFE_CALL!>.<!>length
|
|
|
|
if (x != null) {
|
|
x.length
|
|
}
|
|
}
|
|
|
|
if (x is String) {
|
|
x.length
|
|
}
|
|
}
|