mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-27 23:20:39 +00:00
38 lines
788 B
Text
38 lines
788 B
Text
error: this loop never actually loops
|
|
--> $DIR/never_loop.rs:8:5
|
|
|
|
|
8 | / loop {
|
|
9 | | println!("This is only ever printed once");
|
|
10 | | break;
|
|
11 | | }
|
|
| |_____^
|
|
|
|
|
note: lint level defined here
|
|
--> $DIR/never_loop.rs:4:9
|
|
|
|
|
4 | #![deny(never_loop)]
|
|
| ^^^^^^^^^^
|
|
|
|
error: this loop never actually loops
|
|
--> $DIR/never_loop.rs:21:5
|
|
|
|
|
21 | / loop {
|
|
22 | | loop {
|
|
23 | | // another one
|
|
24 | | break;
|
|
25 | | }
|
|
26 | | break;
|
|
27 | | }
|
|
| |_____^
|
|
|
|
error: this loop never actually loops
|
|
--> $DIR/never_loop.rs:22:9
|
|
|
|
|
22 | / loop {
|
|
23 | | // another one
|
|
24 | | break;
|
|
25 | | }
|
|
| |_________^
|
|
|
|
error: aborting due to 3 previous errors
|
|
|