$cargo fmt

write-by-ref
k-nasa 5 years ago
parent c31861aa65
commit cc21bdf068

@ -40,7 +40,7 @@ where
Some(_) => { Some(_) => {
cx.waker().wake_by_ref(); cx.waker().wake_by_ref();
Poll::Pending Poll::Pending
}, }
None => Poll::Ready(None), None => Poll::Ready(None),
} }
} }

@ -40,7 +40,7 @@ where
Some(_) => { Some(_) => {
cx.waker().wake_by_ref(); cx.waker().wake_by_ref();
Poll::Pending Poll::Pending
}, }
None => Poll::Ready(None), None => Poll::Ready(None),
} }
} }

@ -38,10 +38,12 @@ where
match next { match next {
Some(v) => match self.as_mut().predicate() { Some(v) => match self.as_mut().predicate() {
Some(p) => if !p(&v) { Some(p) => {
if !p(&v) {
*self.as_mut().predicate() = None; *self.as_mut().predicate() = None;
return Poll::Ready(Some(v)); return Poll::Ready(Some(v));
}, }
}
None => return Poll::Ready(Some(v)), None => return Poll::Ready(Some(v)),
}, },
None => return Poll::Ready(None), None => return Poll::Ready(None),

Loading…
Cancel
Save