Add test for outdated smart cast with elvis issue
#KT-5335 Obsolete
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
// !DIAGNOSTICS: -UNUSED_VARIABLE
|
||||
|
||||
// KT-5335
|
||||
|
||||
fun foo(p1: String?, p2: String?) {
|
||||
if (p2 != null) {
|
||||
val v = p1 ?: <!DEBUG_INFO_SMARTCAST!>p2<!>
|
||||
val size = v.length
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user