Skip to content

Commit 08766c1

Browse files
committed
chore(deps): bump rand_core to 0.10.0-rc-4
1 parent e4f6bce commit 08766c1

3 files changed

Lines changed: 40 additions & 37 deletions

File tree

Cargo.lock

Lines changed: 27 additions & 27 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@ const-oid = { version = "0.10", default-features = false }
1818
crypto-bigint = { version = "0.7.0-rc.16", default-features = false, features = ["zeroize", "alloc"] }
1919
crypto-primes = { version = "0.7.0-pre.6", default-features = false }
2020
digest = { version = "0.11.0-rc.4", default-features = false, features = ["alloc", "oid"] }
21-
rand_core = { version = "0.10.0-rc-2", default-features = false }
21+
rand_core = { version = "0.10.0-rc-4", default-features = false }
2222
signature = { version = "3.0.0-rc.5", default-features = false, features = ["alloc", "digest", "rand_core"] }
2323
zeroize = { version = "1.8", features = ["alloc"] }
2424

2525
# optional dependencies
2626
crypto-common = { version = "0.2.0-rc.8", optional = true, features = ["getrandom"] }
2727
pkcs1 = { version = "0.8.0-rc.3", optional = true, default-features = false, features = ["alloc", "pem"] }
28-
pkcs8 = { version = "0.11.0-rc.8", optional = true, default-features = false, features = ["alloc", "pem"] }
28+
pkcs8 = { version = "0.11.0-rc.9", optional = true, default-features = false, features = ["alloc", "pem"] }
2929
serdect = { version = "0.4", optional = true }
3030
sha1 = { version = "0.11.0-rc.3", optional = true, default-features = false, features = ["oid"] }
3131
sha2 = { version = "0.11.0-rc.3", optional = true, default-features = false, features = ["oid"] }
@@ -38,7 +38,7 @@ hex-literal = "1"
3838
proptest = "1"
3939
serde_test = "1.0.89"
4040
rand = { version = "0.10.0-rc.5", features = ["chacha"] }
41-
rand_core = { version = "0.10.0-rc-3", default-features = false }
41+
rand_core = { version = "0.10.0-rc-4", default-features = false }
4242
sha1 = { version = "0.11.0-rc.3", default-features = false, features = ["oid"] }
4343
sha2 = { version = "0.11.0-rc.3", default-features = false, features = ["oid"] }
4444
sha3 = { version = "0.11.0-rc.3", default-features = false, features = ["oid"] }
@@ -69,4 +69,5 @@ opt-level = 2
6969
debug = true
7070

7171
[patch.crates-io]
72-
rand = { git = "https://github.com/rust-random/rand" }
72+
rand = { git = "https://github.com/rust-random/rand", branch = "push-nzsxxkozrnpy" }
73+
crypto-primes = { git = "https://github.com/baloo/crypto-primes.git", branch = "baloo/push-zlqkpkvxqksw" }

src/dummy_rng.rs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,24 @@
1-
use rand_core::{CryptoRng, RngCore};
1+
use core::convert::Infallible;
2+
use rand_core::{TryCryptoRng, TryRngCore};
23

34
/// This is a dummy RNG for cases when we need a concrete RNG type
45
/// which does not get used.
56
#[derive(Copy, Clone)]
67
pub(crate) struct DummyRng;
78

8-
impl RngCore for DummyRng {
9-
fn next_u32(&mut self) -> u32 {
9+
impl TryRngCore for DummyRng {
10+
type Error = Infallible;
11+
fn try_next_u32(&mut self) -> Result<u32, Self::Error> {
1012
unimplemented!();
1113
}
1214

13-
fn next_u64(&mut self) -> u64 {
15+
fn try_next_u64(&mut self) -> Result<u64, Self::Error> {
1416
unimplemented!();
1517
}
1618

17-
fn fill_bytes(&mut self, _: &mut [u8]) {
19+
fn try_fill_bytes(&mut self, _: &mut [u8]) -> Result<(), Self::Error> {
1820
unimplemented!();
1921
}
2022
}
2123

22-
impl CryptoRng for DummyRng {}
24+
impl TryCryptoRng for DummyRng {}

0 commit comments

Comments
 (0)