diff --git a/Cargo.toml b/Cargo.toml index 1975ff69..5f80353f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -26,7 +26,8 @@ cortex-m-semihosting = "0.3" [dev-dependencies.rand] default-features = false -version = "0.5.5" +features = ["small_rng"] +version = "0.7" [target.'cfg(not(target_os = "none"))'.dev-dependencies] compiletest_rs = "0.3.25" diff --git a/examples/rand.rs b/examples/rand.rs index ec3afaae..358868b4 100644 --- a/examples/rand.rs +++ b/examples/rand.rs @@ -16,8 +16,8 @@ use rand::SeedableRng; // the program entry point #[entry] fn main() -> ! { - let seed: [u8; 32] = [0; 32]; - let mut rng = rand::ChaChaRng::from_seed(seed); + let seed: [u8; 16] = [0; 16]; + let mut rng = rand::rngs::SmallRng::from_seed(seed); let _ = rng.gen::(); loop {} diff --git a/macros/Cargo.toml b/macros/Cargo.toml index c53ec891..4e2b56df 100644 --- a/macros/Cargo.toml +++ b/macros/Cargo.toml @@ -21,8 +21,9 @@ features = ["extra-traits", "full"] version = "1.0" [dependencies.rand] -version = "0.5.5" default-features = false +features = ["small_rng"] +version = "0.7" [dev-dependencies] cortex-m-rt = { path = "..", version = "0.6" }