Skip to content

Commit 939614b

Browse files
committed
Fix clippy::redundant_closure warning
1 parent 26493b5 commit 939614b

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

futures-test/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
)
1616
))]
1717
#![allow(clippy::if_then_panic)]
18+
1819
#[cfg(not(feature = "std"))]
1920
compile_error!(
2021
"`futures-test` must have the `std` feature activated, this is a default-active feature"

futures-util/src/future/future/shared.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ where
140140
/// can change the strong count at any time, including potentially between calling this method
141141
/// and acting on the result.
142142
pub fn strong_count(&self) -> Option<usize> {
143-
self.inner.as_ref().map(|arc| Arc::strong_count(arc))
143+
self.inner.as_ref().map(Arc::strong_count)
144144
}
145145

146146
/// Gets the number of weak pointers to this allocation.
@@ -153,7 +153,7 @@ where
153153
/// can change the weak count at any time, including potentially between calling this method
154154
/// and acting on the result.
155155
pub fn weak_count(&self) -> Option<usize> {
156-
self.inner.as_ref().map(|arc| Arc::weak_count(arc))
156+
self.inner.as_ref().map(Arc::weak_count)
157157
}
158158
}
159159

0 commit comments

Comments
 (0)