Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
Signed-off-by: Yuuki Takano <[email protected]>
  • Loading branch information
ytakano committed Dec 25, 2024
1 parent 5870044 commit 4f776f9
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions futures-util/src/async_await/random.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,9 @@ fn random() -> u64 {
x ^= x >> 12;
x ^= x << 25;
x ^= x >> 27;
x = x.wrapping_mul(0x2545_f491_4f6c_dd1d);
}

let result = x.wrapping_mul(0x2545_f491_4f6c_dd1d) as u64;
RNG.store(result as usize, Ordering::Relaxed);

result
RNG.store(x, Ordering::Relaxed);
x as u64
}

0 comments on commit 4f776f9

Please sign in to comment.