@@ -83,8 +83,8 @@ pub mod le;
83
83
/// output (except by communicating that the release has breaking changes).
84
84
///
85
85
/// Typically implementators will implement only one of the methods available
86
- /// in this trait directly, then use the helper functions from the [`impls`]
87
- /// module to implement the other methods.
86
+ /// in this trait directly, then use the helper functions from the
87
+ /// [`rand_core::impls`] module to implement the other methods.
88
88
///
89
89
/// It is recommended that implementations also implement:
90
90
///
@@ -131,7 +131,7 @@ pub mod le;
131
131
/// [rand]: https://crates.io/crates/rand
132
132
/// [`Rng`]: ../rand/trait.Rng.html
133
133
/// [`SeedableRng`]: trait.SeedableRng.html
134
- /// [`impls`]: impls/index.html
134
+ /// [`rand_core:: impls`]: ../rand_core/ impls/index.html
135
135
/// [`try_fill_bytes`]: trait.RngCore.html#tymethod.try_fill_bytes
136
136
/// [`fill_bytes`]: trait.RngCore.html#tymethod.fill_bytes
137
137
/// [`next_u32`]: trait.RngCore.html#tymethod.next_u32
@@ -143,23 +143,23 @@ pub trait RngCore {
143
143
/// RNGs must implement at least one method from this trait directly. In
144
144
/// the case this method is not implemented directly, it can be implemented
145
145
/// using `self.next_u64() as u32` or
146
- /// [via `fill_bytes`](impls/fn.next_u32_via_fill.html).
146
+ /// [via `fill_bytes`](../rand_core/ impls/fn.next_u32_via_fill.html).
147
147
fn next_u32 ( & mut self ) -> u32 ;
148
148
149
149
/// Return the next random `u64`.
150
150
///
151
151
/// RNGs must implement at least one method from this trait directly. In
152
152
/// the case this method is not implemented directly, it can be implemented
153
- /// [via `next_u32`](impls/fn.next_u64_via_u32.html) or
154
- /// [via `fill_bytes`](impls/fn.next_u64_via_fill.html).
153
+ /// [via `next_u32`](../rand_core/ impls/fn.next_u64_via_u32.html) or
154
+ /// [via `fill_bytes`](../rand_core/ impls/fn.next_u64_via_fill.html).
155
155
fn next_u64 ( & mut self ) -> u64 ;
156
156
157
157
/// Fill `dest` with random data.
158
158
///
159
159
/// RNGs must implement at least one method from this trait directly. In
160
160
/// the case this method is not implemented directly, it can be implemented
161
- /// [via `next_u32`](impls/fn.fill_bytes_via_u32.html) or
162
- /// [via `next_u64`](impls/fn.fill_bytes_via_u64.html) or
161
+ /// [via `next_u32`](../rand_core/ impls/fn.fill_bytes_via_u32.html) or
162
+ /// [via `next_u64`](../rand_core/ impls/fn.fill_bytes_via_u64.html) or
163
163
/// via `try_fill_bytes`; if this generator can fail the implementation
164
164
/// must choose how best to handle errors here (e.g. panic with a
165
165
/// descriptive message or log a warning and retry a few times).
@@ -329,7 +329,7 @@ pub trait SeedableRng: Sized {
329
329
///
330
330
/// Seeding a small PRNG from another small PRNG is possible, but
331
331
/// something to be careful with. An extreme example of how this can go
332
- /// wrong is seeding an [`XorShiftRng`] from another [`XorShiftRng`] , which
332
+ /// wrong is seeding an Xorshift RNG from another Xorshift RNG , which
333
333
/// will effectively clone the generator. In general seeding from a
334
334
/// generator which is hard to predict is probably okay.
335
335
///
@@ -338,7 +338,6 @@ pub trait SeedableRng: Sized {
338
338
///
339
339
/// [`NewRng`]: ../rand/trait.NewRng.html
340
340
/// [`OsRng`]: ../rand/os/struct.OsRng.html
341
- /// [`XorShiftRng`]: ../rand/struct.XorShiftRng.html
342
341
fn from_rng < R : RngCore > ( mut rng : R ) -> Result < Self , Error > {
343
342
let mut seed = Self :: Seed :: default ( ) ;
344
343
rng. try_fill_bytes ( seed. as_mut ( ) ) ?;
0 commit comments