Skip to content

Commit 6c552a7

Browse files
committed
Fix clippy errors
1 parent 3df6f46 commit 6c552a7

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

futures-core/src/future/future_obj.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,10 @@ impl<'a, T> LocalFutureObj<'a, T> {
4747
}
4848
}
4949

50-
/// Converts the `LocalFutureObj` into a `FutureObj`
50+
/// Converts the `LocalFutureObj` into a `FutureObj`.
51+
///
52+
/// # Safety
53+
///
5154
/// To make this operation safe one has to ensure that the `UnsafeFutureObj`
5255
/// instance from which this `LocalFutureObj` was created actually
5356
/// implements `Send`.

futures-util/src/task/waker.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ where
3030
// FIXME: panics on Arc::clone / refcount changes could wreak havoc on the
3131
// code here. We should guard against this by aborting.
3232

33+
#[allow(clippy::redundant_clone)] // The clone here isn't actually redundant.
3334
unsafe fn increase_refcount<T: ArcWake>(data: *const ()) {
3435
// Retain Arc, but don't touch refcount by wrapping in ManuallyDrop
3536
let arc = mem::ManuallyDrop::new(Arc::<T>::from_raw(data as *const T));

0 commit comments

Comments
 (0)