From 0da23aad772afb22db8edf73ac0f034c5ada3bde Mon Sep 17 00:00:00 2001 From: Carl Lerche Date: Tue, 5 Nov 2019 23:38:52 -0800 Subject: fix clippy (#1737) --- tokio/src/sync/watch.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'tokio/src/sync/watch.rs') diff --git a/tokio/src/sync/watch.rs b/tokio/src/sync/watch.rs index 30f1603f..928c2c46 100644 --- a/tokio/src/sync/watch.rs +++ b/tokio/src/sync/watch.rs @@ -298,7 +298,6 @@ impl Receiver { impl futures_core::Stream for Receiver { type Item = T; - #[allow(clippy::map_clone)] // false positive: https://github.com/rust-lang/rust-clippy/issues/3274 fn poll_next(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll> { use std::future::Future; @@ -306,7 +305,7 @@ impl futures_core::Stream for Receiver { pin_mut!(fut); let item = ready!(fut.poll(cx)); - Ready(item.map(|v_ref| v_ref.clone())) + Ready(item.map(|v_ref| v_ref)) } } -- cgit v1.2.3