Skip to content

Commit

Permalink
Update rand_core requirement from 0.6.4 to 0.9.0 in /nrf-hal-common (#…
Browse files Browse the repository at this point in the history
…511)

* Update rand_core requirement from 0.6.4 to 0.9.0 in /nrf-hal-common

Updates the requirements on [rand_core](https://github.com/rust-random/rand) to permit the latest version.
- [Release notes](https://github.com/rust-random/rand/releases)
- [Changelog](https://github.com/rust-random/rand/blob/master/CHANGELOG.md)
- [Commits](rust-random/rand@rand_core-0.6.4...0.9.0)

---
updated-dependencies:
- dependency-name: rand_core
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>

* Fix build after rand_core update.

* Update rand_core in example too.

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Andrew Walbran <[email protected]>
  • Loading branch information
dependabot[bot] and qwandor authored Jan 28, 2025
1 parent 6f3b319 commit 3c4bace
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 7 deletions.
2 changes: 1 addition & 1 deletion examples/ccm-demo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ publish = false
cortex-m = { version = "0.7.3", features = ["critical-section-single-core"] }
cortex-m-rt = "0.7.0"
rtt-target = "0.6.0"
rand_core = "0.6.3"
rand_core = "0.9.0"

nrf52805-hal = { path = "../../nrf52805-hal", features = ["rt"], optional = true }
nrf52810-hal = { path = "../../nrf52810-hal", features = ["rt"], optional = true }
Expand Down
2 changes: 1 addition & 1 deletion nrf-hal-common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ embedded-io = "0.6.1"
embedded-storage = "0.3.1"
fixed = "1.25.1"
nb = "1.1.0"
rand_core = "0.6.4"
rand_core = "0.9.0"

[dependencies.void]
default-features = false
Expand Down
5 changes: 0 additions & 5 deletions nrf-hal-common/src/rng.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,6 @@ impl RngCore for Rng {
fn fill_bytes(&mut self, dest: &mut [u8]) {
self.random(dest)
}

fn try_fill_bytes(&mut self, dest: &mut [u8]) -> Result<(), rand_core::Error> {
self.fill_bytes(dest);
Ok(())
}
}

impl CryptoRng for Rng {}

0 comments on commit 3c4bace

Please sign in to comment.