Unbreak the clippy test
This commit is contained in:
parent
191b0806d2
commit
48b4aeabf8
@ -3,6 +3,7 @@
|
|||||||
#![feature(range_is_empty)]
|
#![feature(range_is_empty)]
|
||||||
#![warn(clippy::len_zero)]
|
#![warn(clippy::len_zero)]
|
||||||
#![allow(unused)]
|
#![allow(unused)]
|
||||||
|
#![allow(stable_features)] // TODO: https://github.com/rust-lang/rust-clippy/issues/5956
|
||||||
|
|
||||||
mod issue_3807 {
|
mod issue_3807 {
|
||||||
// With the feature enabled, `is_empty` should be suggested
|
// With the feature enabled, `is_empty` should be suggested
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
#![feature(range_is_empty)]
|
#![feature(range_is_empty)]
|
||||||
#![warn(clippy::len_zero)]
|
#![warn(clippy::len_zero)]
|
||||||
#![allow(unused)]
|
#![allow(unused)]
|
||||||
|
#![allow(stable_features)] // TODO: https://github.com/rust-lang/rust-clippy/issues/5956
|
||||||
|
|
||||||
mod issue_3807 {
|
mod issue_3807 {
|
||||||
// With the feature enabled, `is_empty` should be suggested
|
// With the feature enabled, `is_empty` should be suggested
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
error: length comparison to zero
|
error: length comparison to zero
|
||||||
--> $DIR/len_zero_ranges.rs:10:17
|
--> $DIR/len_zero_ranges.rs:11:17
|
||||||
|
|
|
|
||||||
LL | let _ = (0..42).len() == 0;
|
LL | let _ = (0..42).len() == 0;
|
||||||
| ^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `(0..42).is_empty()`
|
| ^^^^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `(0..42).is_empty()`
|
||||||
|
Loading…
Reference in New Issue
Block a user