KT-234 Force when() expressions to have an 'else' branch

KT-973 Unreachable code
This commit is contained in:
svtk
2012-01-18 13:31:42 +04:00
parent 94e3cc9976
commit becd713111
23 changed files with 175 additions and 50 deletions
@@ -15,12 +15,11 @@ fun testUnresolved() {
foo1(<!UNRESOLVED_REFERENCE!>i<!>)
s.<!UNRESOLVED_REFERENCE!>foo<!>()
when(<!UNRESOLVED_REFERENCE!>a<!>) {
<!NO_ELSE_IN_WHEN!>when<!>(<!UNRESOLVED_REFERENCE!>a<!>) {
is Int -> <!UNRESOLVED_REFERENCE!>a<!>
is String -> <!UNRESOLVED_REFERENCE!>a<!>
}
//TODO
for (j in <!UNRESOLVED_REFERENCE!>collection<!>) {
var i: Int = j
i += 1