Partial body resolve: added more tests

This commit is contained in:
Valentin Kipyatkov
2014-11-21 12:19:23 +03:00
parent 0dd77a8ed3
commit 058af69078
13 changed files with 181 additions and 3 deletions
@@ -0,0 +1,31 @@
Resolve target: value-parameter val p: kotlin.String? smart-cast to kotlin.String
----------------------------------------------
fun foo(p: String?, x: Boolean, y: Boolean, z: Boolean, t: Boolean) {
if (p == null) {
if (x) {
// STATEMENT DELETED: print("x")
error("error")
}
else if (y) {
// STATEMENT DELETED: print("y")
if (z) {
// STATEMENT DELETED: print("z")
return
}
else {
throw Exception()
}
}
else {
if (t) {
// STATEMENT DELETED: print("t")
return
}
else {
return
}
}
}
<caret>p.length
}