Skip to content

Commit c938001

Browse files
committed
Ignore clippy::let_underscore_future lint
``` warning: non-binding `let` on a future --> futures-util/src/future/select_all.rs:61:17 | 61 | let _ = self.inner.swap_remove(idx); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: consider awaiting the future or dropping explicitly with `std::mem::drop` = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_future = note: `#[warn(clippy::let_underscore_future)]` on by default warning: non-binding `let` on a future --> futures/tests/async_await_macros.rs:385:5 | 385 | let _ = async { join!(async {}, async {}) }; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: consider awaiting the future or dropping explicitly with `std::mem::drop` = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_future = note: `#[warn(clippy::let_underscore_future)]` on by default warning: non-binding `let` on a future --> futures/tests/async_await_macros.rs:390:5 | 390 | let _ = async { try_join!(async { Ok::<(), ()>(()) }, async { Ok::<(), ()>(()) },) }; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: consider awaiting the future or dropping explicitly with `std::mem::drop` = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_future ```
1 parent 3b0378b commit c938001

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

futures-util/src/future/select_all.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ impl<Fut: Future + Unpin> Future for SelectAll<Fut> {
5858
});
5959
match item {
6060
Some((idx, res)) => {
61+
#[allow(clippy::let_underscore_future)]
6162
let _ = self.inner.swap_remove(idx);
6263
let rest = mem::take(&mut self.inner);
6364
Poll::Ready((res, idx, rest))

futures/tests/async_await_macros.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -380,11 +380,13 @@ fn try_join_size() {
380380
assert_eq!(mem::size_of_val(&fut), 48);
381381
}
382382

383+
#[allow(clippy::let_underscore_future)]
383384
#[test]
384385
fn join_doesnt_require_unpin() {
385386
let _ = async { join!(async {}, async {}) };
386387
}
387388

389+
#[allow(clippy::let_underscore_future)]
388390
#[test]
389391
fn try_join_doesnt_require_unpin() {
390392
let _ = async { try_join!(async { Ok::<(), ()>(()) }, async { Ok::<(), ()>(()) },) };

0 commit comments

Comments
 (0)