mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-15 10:07:30 +00:00
18 lines
352 B
Rust
18 lines
352 B
Rust
// run-rustfix
|
|
|
|
#![warn(clippy::len_zero)]
|
|
#![allow(unused)]
|
|
|
|
// Now that `Range(Inclusive)::is_empty` is stable (1.47), we can always suggest this
|
|
mod issue_3807 {
|
|
fn suggestion_is_fine_range() {
|
|
let _ = (0..42).is_empty();
|
|
}
|
|
|
|
fn suggestion_is_fine_range_inclusive() {
|
|
let _ = (0_u8..=42).is_empty();
|
|
}
|
|
}
|
|
|
|
fn main() {}
|