Merge pull request #568 from stjepang/fix-random

Fix rng use in Stream::merge
new-scheduler
Yoshua Wuyts 5 years ago committed by GitHub
commit 6f19165e0e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -44,7 +44,7 @@ where
fn poll_next(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Option<Self::Item>> {
let this = self.project();
if utils::random(1) == 1 {
if utils::random(2) == 0 {
poll_next_in_order(this.left, this.right, cx)
} else {
poll_next_in_order(this.right, this.left, cx)

Loading…
Cancel
Save