'Else' is not required in 'when' if Unit is expected
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
fun box(): String {
|
||||
val x = 1
|
||||
when (x) {
|
||||
1 -> return "OK"
|
||||
}
|
||||
return "Fail 1"
|
||||
}
|
||||
Reference in New Issue
Block a user