We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 6184710 + 66ad544 commit fdc6690Copy full SHA for fdc6690
clippy_lints/src/methods/mod.rs
@@ -798,8 +798,9 @@ declare_clippy_lint! {
798
declare_clippy_lint! {
799
/// **What it does:** Checks for the use of `iter.nth(0)`.
800
///
801
- /// **Why is this bad?** `iter.nth(0)` is unnecessary, and `iter.next()`
802
- /// is more readable.
+ /// **Why is this bad?** `iter.next()` is equivalent to
+ /// `iter.nth(0)`, as they both consume the next element,
803
+ /// but is more readable.
804
805
/// **Known problems:** None.
806
0 commit comments