Fix for KT-9022: Wrong result when use break in if condition
#KT-9022 Fixed
This commit is contained in:
+9
@@ -0,0 +1,9 @@
|
||||
fun box(): String {
|
||||
var cycle = true;
|
||||
while (true) {
|
||||
if (true && break) {
|
||||
return "fail"
|
||||
}
|
||||
}
|
||||
return "OK"
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
fun box(): String {
|
||||
var cycle = true;
|
||||
while (true) {
|
||||
if (true || break) {
|
||||
return "OK"
|
||||
}
|
||||
}
|
||||
return "fail"
|
||||
}
|
||||
Reference in New Issue
Block a user