From a6882831fd818be4d2225b3686fe741ea354ac61 Mon Sep 17 00:00:00 2001 From: bluss Date: Mon, 21 Dec 2020 20:00:19 +0100 Subject: [PATCH] FIX: Update ndarray-rand quickcheck after rand update (quickcheck is still on rand 0.7, but the rest of the crate uses rand 0.8) --- ndarray-rand/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ndarray-rand/src/lib.rs b/ndarray-rand/src/lib.rs index 2493df8bd..7dc95ec5d 100644 --- a/ndarray-rand/src/lib.rs +++ b/ndarray-rand/src/lib.rs @@ -305,7 +305,7 @@ pub enum SamplingStrategy { #[cfg(feature = "quickcheck")] impl Arbitrary for SamplingStrategy { fn arbitrary(g: &mut G) -> Self { - if g.gen_bool(0.5) { + if bool::arbitrary(g) { SamplingStrategy::WithReplacement } else { SamplingStrategy::WithoutReplacement