Fix an endless loop in the tests.
This commit is contained in:
parent
35058287ce
commit
6870638c3f
@ -55,10 +55,10 @@ fn test_loop_with_block() -> bool {
|
||||
fn test_loop_with_nests() -> bool {
|
||||
loop {
|
||||
if true {
|
||||
let _ = true;
|
||||
break true;
|
||||
}
|
||||
else {
|
||||
break true;
|
||||
let _ = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -43,9 +43,9 @@ error: missing return statement
|
||||
| ^^^^^^^^^^ help: change `break` to `return` as shown: `return true`
|
||||
|
||||
error: missing return statement
|
||||
--> $DIR/implicit_return.rs:61:13
|
||||
--> $DIR/implicit_return.rs:58:13
|
||||
|
|
||||
61 | break true;
|
||||
58 | break true;
|
||||
| ^^^^^^^^^^ help: change `break` to `return` as shown: `return true`
|
||||
|
||||
error: missing return statement
|
||||
|
Loading…
Reference in New Issue
Block a user