]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/len_zero_ranges.rs
Rollup merge of #75875 - pickfire:patch-4, r=jyn514
[rust.git] / src / tools / clippy / tests / ui / len_zero_ranges.rs
1 // run-rustfix
2
3 #![feature(range_is_empty)]
4 #![warn(clippy::len_zero)]
5 #![allow(unused)]
6 #![allow(stable_features)] // TODO: https://github.com/rust-lang/rust-clippy/issues/5956
7
8 mod issue_3807 {
9     // With the feature enabled, `is_empty` should be suggested
10     fn suggestion_is_fine() {
11         let _ = (0..42).len() == 0;
12     }
13 }
14
15 fn main() {}