From 6e473865396e095e154bbd1b8ae63c72d1b91339 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Tue, 2 Jan 2024 13:13:34 +0000 Subject: [PATCH] clippy: Add an allow to work around a clippy bug clippy in current stable thinks |(a, b)| (a, b) is always the identity function, but due to match ergonomics, it might be an implicit copy. This is fixed in nightly by https://github.com/rust-lang/rust-clippy/pull/11792 --- crates/tor-netdir/src/params.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/tor-netdir/src/params.rs b/crates/tor-netdir/src/params.rs index d5f6436ce..71373da72 100644 --- a/crates/tor-netdir/src/params.rs +++ b/crates/tor-netdir/src/params.rs @@ -601,6 +601,9 @@ mod test { } #[test] + // TODO remove when this upstream bug is fixed + /// https://github.com/rust-lang/rust-clippy/issues/11764 + #[allow(clippy::map_identity)] fn all_parameters() { use std::time::Duration; let mut p = NetParameters::default();