Skip to content

Commit d1e0ab1

Browse files
authored
Merge pull request #226 from pitdicker/fix_docs
Fix documentation warnings
2 parents 2c1965b + d71da3b commit d1e0ab1

File tree

4 files changed

+12
-11
lines changed

4 files changed

+12
-11
lines changed

src/jitter.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ const MEMORY_SIZE: usize = MEMORY_BLOCKS * MEMORY_BLOCKSIZE;
3232
/// This is a true random number generator, as opposed to pseudo-random
3333
/// generators. Random numbers generated by `JitterRng` can be seen as fresh
3434
/// entropy. A consequence is that is orders of magnitude slower than `OsRng`
35-
/// and PRNGs (about 10^3 .. 10^6 slower).
35+
/// and PRNGs (about 10<sup>3</sup>..10<sup>6</sup> slower).
3636
///
3737
/// There are very few situations where using this RNG is appropriate. Only very
3838
/// few applications require true entropy. A normal PRNG can be statistically
@@ -574,8 +574,8 @@ impl JitterRng {
574574
///
575575
/// # Example
576576
///
577-
/// Use `timer_stats` to run the [NIST SP 800-90B Entropy Estimation Suite]
578-
/// (https://github.com/usnistgov/SP800-90B_EntropyAssessment).
577+
/// Use `timer_stats` to run the [NIST SP 800-90B Entropy Estimation Suite](
578+
/// https://github.com/usnistgov/SP800-90B_EntropyAssessment).
579579
///
580580
/// This is the recommended way to test the quality of `JitterRng`. It
581581
/// should be run before using the RNG on untested hardware, after changes

src/prng/isaac.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -79,14 +79,14 @@ const RAND_SIZE: usize = 1 << RAND_SIZE_LEN;
7979
/// 2 * 256 * 4 = 2 kb to hold the state and results.
8080
///
8181
/// ## References
82-
/// [1]: Bob Jenkins, [*ISAAC: A fast cryptographic random number generator*]
83-
/// (http://burtleburtle.net/bob/rand/isaacafa.html)
82+
/// [1]: Bob Jenkins, [*ISAAC: A fast cryptographic random number generator*](
83+
/// http://burtleburtle.net/bob/rand/isaacafa.html)
8484
///
85-
/// [2]: Bob Jenkins, [*ISAAC and RC4*]
86-
/// (http://burtleburtle.net/bob/rand/isaac.html)
85+
/// [2]: Bob Jenkins, [*ISAAC and RC4*](
86+
/// http://burtleburtle.net/bob/rand/isaac.html)
8787
///
88-
/// [3]: Jean-Philippe Aumasson, [*On the pseudo-random generator ISAAC*]
89-
/// (https://eprint.iacr.org/2006/438)
88+
/// [3]: Jean-Philippe Aumasson, [*On the pseudo-random generator ISAAC*](
89+
/// https://eprint.iacr.org/2006/438)
9090
pub struct IsaacRng {
9191
rsl: [u32; RAND_SIZE],
9292
mem: [w32; RAND_SIZE],

src/prng/isaac64.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,8 @@ const RAND_SIZE: usize = 1 << RAND_SIZE_LEN;
6969
///
7070
/// See for more information the description in rand::prng::IsaacRng.
7171
///
72-
/// [1]: Bob Jenkins, [*ISAAC and RC4*]
73-
/// (http://burtleburtle.net/bob/rand/isaac.html)
72+
/// [1]: Bob Jenkins, [*ISAAC and RC4*](
73+
/// http://burtleburtle.net/bob/rand/isaac.html)
7474
pub struct Isaac64Rng {
7575
rsl: [u64; RAND_SIZE],
7676
mem: [w64; RAND_SIZE],

src/seq.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ use super::Rng;
2222
/// Randomly sample `amount` elements from a finite iterator.
2323
///
2424
/// The following can be returned:
25+
///
2526
/// - `Ok`: `Vec` of `amount` non-repeating randomly sampled elements. The order is not random.
2627
/// - `Err`: `Vec` of all the elements from `iterable` in sequential order. This happens when the
2728
/// length of `iterable` was less than `amount`. This is considered an error since exactly

0 commit comments

Comments
 (0)