Skip to content

Commit

Permalink
better comments
Browse files Browse the repository at this point in the history
  • Loading branch information
TheIronBorn committed May 31, 2018
1 parent e9c7581 commit ab1087f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/bigrand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,9 @@ impl<R: Rng + ?Sized> RandBigInt for R {
let mut data = vec![BigDigit::default(); digits + (rem > 0) as usize];
// `fill_bytes` is faster than many `gen::<u32>` calls
self.fill_bytes(data[..].as_byte_slice_mut());
// per the `Rng::fill` source, might be unnecessary if
// reproducibility across architectures is not desired
// Swap bytes per the `Rng::fill` source. This might be
// unnecessary if reproducibility across architectures is not
// desired.
data.to_le();
if rem > 0 {
data[digits] >>= BITS - rem;
Expand Down

0 comments on commit ab1087f

Please sign in to comment.