Files
kotlin-fork/compiler/testData/diagnostics/tests/smartCasts/varnotnull/nestedDoWhile.fir.kt
T
2020-02-03 16:45:20 +03:00

15 lines
292 B
Kotlin
Vendored

fun x(): Boolean { return true }
public fun foo(pp: String?, rr: String?): Int {
var p = pp
var r = rr
do {
do {
p!!.length
} while (r == null)
} while (!x())
// Auto cast possible
r.length
// Auto cast possible
return p.length
}