mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-27 15:11:30 +00:00
Fix an endless loop in the tests.
This commit is contained in:
parent
35058287ce
commit
6870638c3f
2 changed files with 4 additions and 4 deletions
|
@ -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 a new issue