🚨 Fix a rust-clippy warning

* https://rust-lang.github.io/rust-clippy/master/#redundant_pattern_matching
This commit is contained in:
Dima Pristupa 2021-10-25 15:39:40 +03:00 committed by Taiki Endo
parent a86d9c5f73
commit 906fdef2ef
1 changed files with 1 additions and 1 deletions

View File

@ -97,7 +97,7 @@ impl Executor {
// `Pin<Box<dyn Future<Output = T> + Send + 'static>>`.
// We can get a `Pin<&mut dyn Future + Send + 'static>`
// from it by calling the `Pin::as_mut` method.
if let Poll::Pending = future.as_mut().poll(context) {
if future.as_mut().poll(context).is_pending() {
// We're not done processing the future, so put it
// back in its task to be run again in the future.
*future_slot = Some(future);