Skip to content

Commit cd9d989

Browse files
authored
Remove rng parameter of ReseedingRng::new (rust-random#1533)
The `rng` parameter seems redundant in `ReseedingRng::new` (aside from the type specification).
1 parent 3856325 commit cd9d989

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

benches/generators.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ pub fn reseeding_bytes(c: &mut Criterion) {
201201
fn bench(g: &mut BenchmarkGroup<WallTime>, thresh: u64) {
202202
let name = format!("chacha20_{}k", thresh);
203203
g.bench_function(name.as_str(), |b| {
204-
let mut rng = ReseedingRng::new(ChaCha20Core::from_os_rng(), thresh * 1024, OsRng);
204+
let mut rng = ReseedingRng::<ChaCha20Core, _>::new(thresh * 1024, OsRng).unwrap();
205205
let mut buf = [0u8; 1024 * 1024];
206206
b.iter(|| {
207207
rng.fill_bytes(&mut buf);

0 commit comments

Comments
 (0)