Skip to content

Commit

Permalink
Remove #[allow(clippy::needless_lifetimes)]
Browse files Browse the repository at this point in the history
  • Loading branch information
taiki-e committed Apr 18, 2019
1 parent 1ee408b commit 22422bd
Show file tree
Hide file tree
Showing 9 changed files with 0 additions and 9 deletions.
1 change: 0 additions & 1 deletion futures-util/src/future/maybe_done.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ impl<Fut: Future> MaybeDone<Fut> {
/// future has been completed and [`take_output`](MaybeDone::take_output)
/// has not yet been called.
#[inline]
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn output_mut<'a>(self: Pin<&'a mut Self>) -> Option<&'a mut Fut::Output> {
unsafe {
let this = Pin::get_unchecked_mut(self);
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/sink/map_err.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ impl<Si, F> SinkMapErr<Si, F> {
}

/// Get a pinned reference to the inner sink.
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn get_pin_mut<'a>(self: Pin<&'a mut Self>) -> Pin<&'a mut Si> {
unsafe { Pin::map_unchecked_mut(self, |x| &mut x.sink) }
}
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/sink/with.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ enum State<Fut, T> {
}

impl<Fut, T> State<Fut, T> {
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
#[allow(clippy::wrong_self_convention)]
fn as_pin_mut<'a>(
self: Pin<&'a mut Self>,
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/sink/with_flat_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ where
}

/// Get a pinned mutable reference to the inner sink.
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn get_pin_mut<'a>(self: Pin<&'a mut Self>) -> Pin<&'a mut Si> {
unsafe { Pin::map_unchecked_mut(self, |x| &mut x.sink) }
}
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/stream/buffer_unordered.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ where
///
/// Note that care must be taken to avoid tampering with the state of the
/// stream which may otherwise confuse this combinator.
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn get_pin_mut<'a>(self: Pin<&'a mut Self>) -> Pin<&'a mut St> {
unsafe { Pin::map_unchecked_mut(self, |x| x.get_mut()) }
}
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/stream/buffered.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ where
///
/// Note that care must be taken to avoid tampering with the state of the
/// stream which may otherwise confuse this combinator.
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn get_pin_mut<'a>(self: Pin<&'a mut Self>) -> Pin<&'a mut St> {
unsafe { Pin::map_unchecked_mut(self, |x| x.get_mut()) }
}
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/stream/fuse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ impl<St: Stream> Fuse<St> {
///
/// Note that care must be taken to avoid tampering with the state of the
/// stream which may otherwise confuse this combinator.
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn get_pin_mut<'a>(self: Pin<&'a mut Self>) -> Pin<&'a mut St> {
unsafe { Pin::map_unchecked_mut(self, |x| x.get_mut()) }
}
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/stream/futures_unordered/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,6 @@ impl<Fut> FuturesUnordered<Fut> {
}

/// Returns an iterator that allows modifying each future in the set.
#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
pub fn iter_pin_mut<'a>(self: Pin<&'a mut Self>) -> IterPinMut<'a, Fut> {
IterPinMut {
task: self.head_all,
Expand Down
1 change: 0 additions & 1 deletion futures-util/src/try_future/flatten_sink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ where
FlattenSink(Waiting(future))
}

#[allow(clippy::needless_lifetimes)] // https://github.com/rust-lang/rust/issues/52675
fn project_pin<'a>(
self: Pin<&'a mut Self>
) -> State<Pin<&'a mut Fut>, Pin<&'a mut Si>> {
Expand Down

0 comments on commit 22422bd

Please sign in to comment.