blob: 92a202fd2ddcf31ea40ae3be77a1af7e3c4bfd76 [file] [edit]
error: for loop on unbounded range
--> tests/ui/for_unbounded_range.rs:26:5
|
LL | / for i in 0_u8.. {
LL | |
LL | | do_something(i);
LL | | }
| |_____^
|
= note: `-D clippy::for-unbounded-range` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::for_unbounded_range)]`
help: for loops over unbounded ranges will wrap around and may panic, consider adding an inclusive high bound
|
LL | for i in 0_u8..=u8::MAX {
| ++++++++
error: for loop on unbounded range
--> tests/ui/for_unbounded_range.rs:31:5
|
LL | / for i in '\0'.. {
LL | |
LL | | do_something(i);
LL | | }
| |_____^
|
help: for loops over unbounded ranges will wrap around and may panic, consider adding an inclusive high bound
|
LL | for i in '\0'..=char::MAX {
| ++++++++++
error: aborting due to 2 previous errors