mirror of
https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git
synced 2026-10-25 12:39:18 +03:00
bindings: rust: clippy: silence false-positive on iterator
This was fixed on clippy master [1], but it is still broken on 0.1.70. So
lets silence it until the clippy fix is widely available.
clippy version: clippy 0.1.70 (90c5418 2023-05-31).
[1] 9fa4089410
Reported-by: Kent Gibson <warthog618@gmail.com>
Link: https://lore.kernel.org/r/20230612154055.56556-1-warthog618@gmail.com
Signed-off-by: Erik Schilling <erik.schilling@linaro.org>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: Kent Gibson <warthog618@gmail.com>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
This commit is contained in:
committed by
Bartosz Golaszewski
parent
39189f0bf5
commit
4b8357b368
@@ -54,6 +54,9 @@ impl<'a> Iterator for Events<'a> {
|
||||
}
|
||||
|
||||
fn next(&mut self) -> Option<Self::Item> {
|
||||
// clippy false-positive, fixed in next clippy release:
|
||||
// https://github.com/rust-lang/rust-clippy/issues/9820
|
||||
#[allow(clippy::iter_nth_zero)]
|
||||
self.nth(0)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user