Skip to content

Commit 351edce

Browse files
authored
Merge pull request #711 from dhardy/master
Fix doc links and allow failure of Android test
2 parents 8112daa + 9ffaeb7 commit 351edce

File tree

5 files changed

+34
-5
lines changed

5 files changed

+34
-5
lines changed

.travis.yml

+2
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,8 @@ matrix:
199199
- source ~/.cargo/env || true
200200
script:
201201
- bash utils/ci/script.sh
202+
allow_failures:
203+
- env: TARGET=armv7-linux-androideabi
202204

203205
before_install:
204206
- set -e

rand_jitter/src/lib.rs

+8
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,14 @@
4040
//!
4141
//! [Jitterentropy]: http://www.chronox.de/jent.html
4242
43+
#![doc(html_logo_url = "https://www.rust-lang.org/logos/rust-logo-128x128-blk.png",
44+
html_favicon_url = "https://www.rust-lang.org/favicon.ico",
45+
html_root_url = "https://rust-random.github.io/rand/")]
46+
47+
#![deny(missing_docs)]
48+
#![deny(missing_debug_implementations)]
49+
#![doc(test(attr(allow(unused_variables), deny(warnings))))]
50+
4351
// Note: the C implementation of `Jitterentropy` relies on being compiled
4452
// without optimizations. This implementation goes through lengths to make the
4553
// compiler not optimize out code which does influence timing jitter, but is

src/rngs/small.rs

+6-3
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,13 @@ type Rng = ::rand_pcg::Pcg32;
2424
/// future library versions may use a different internal generator with
2525
/// different output. Further, this generator may not be portable and can
2626
/// produce different output depending on the architecture. If you require
27-
/// reproducible output, use a named RNG. Refer to the documentation on the
28-
/// [`prng`][crate::prng] module.
27+
/// reproducible output, use a named RNG.
28+
/// Refer to [The Book](https://rust-random.github.io/book/guide-rngs.html).
29+
///
2930
///
3031
/// The current algorithm is [`Pcg64Mcg`][rand_pcg::Pcg64Mcg] on 64-bit platforms with Rust version
31-
/// 1.26 and later, or [`Pcg32`][rand_pcg::Pcg32] otherwise.
32+
/// 1.26 and later, or [`Pcg32`][rand_pcg::Pcg32] otherwise. Both are found in
33+
/// the [rand_pcg] crate.
3234
///
3335
/// # Examples
3436
///
@@ -67,6 +69,7 @@ type Rng = ::rand_pcg::Pcg32;
6769
/// [`FromEntropy`]: crate::FromEntropy
6870
/// [`StdRng`]: crate::rngs::StdRng
6971
/// [`thread_rng`]: crate::thread_rng
72+
/// [rand_pcg]: https://crates.io/crates/rand_pcg
7073
#[derive(Clone, Debug)]
7174
pub struct SmallRng(Rng);
7275

src/rngs/std.rs

+6-2
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,20 @@ use rand_hc::Hc128Rng;
1515
/// on the current platform, to be statistically strong and unpredictable
1616
/// (meaning a cryptographically secure PRNG).
1717
///
18-
/// The current algorithm used on all platforms is [HC-128].
18+
/// The current algorithm used on all platforms is [HC-128], found in the
19+
/// [rand_hc] crate.
1920
///
2021
/// Reproducibility of output from this generator is however not required, thus
2122
/// future library versions may use a different internal generator with
2223
/// different output. Further, this generator may not be portable and can
2324
/// produce different output depending on the architecture. If you require
24-
/// reproducible output, use a named RNG, for example [`ChaChaRng`].
25+
/// reproducible output, use a named RNG, for example [`ChaChaRng`] from the
26+
/// [rand_chacha] crate.
2527
///
2628
/// [HC-128]: rand_hc::Hc128Rng
2729
/// [`ChaChaRng`]: rand_chacha::ChaChaRng
30+
/// [rand_hc]: https://crates.io/crates/rand_hc
31+
/// [rand_chacha]: https://crates.io/crates/rand_chacha
2832
#[derive(Clone, Debug)]
2933
pub struct StdRng(Hc128Rng);
3034

tests/wasm_bindgen/src/lib.rs

+12
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
// Copyright 2018 Developers of the Rand project.
2+
//
3+
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
4+
// https://www.apache.org/licenses/LICENSE-2.0> or the MIT license
5+
// <LICENSE-MIT or https://opensource.org/licenses/MIT>, at your
6+
// option. This file may not be copied, modified, or distributed
7+
// except according to those terms.
8+
9+
// Crate to test WASM with the `wasm-bindgen` lib.
10+
11+
#![doc(html_logo_url = "https://www.rust-lang.org/logos/rust-logo-128x128-blk.png")]
12+
113
extern crate rand;
214
extern crate wasm_bindgen;
315
extern crate wasm_bindgen_test;

0 commit comments

Comments
 (0)