Skip to content

Commit

Permalink
[fix-ci-nightly] include Float / FloatCore for non-std builds for flo…
Browse files Browse the repository at this point in the history
…at_sampler
  • Loading branch information
rex-remind101 committed Dec 19, 2022
1 parent 6a958db commit 1ccc872
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 3 additions & 1 deletion proptest/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,10 @@ version = "1.2"
optional = true

[dependencies.num-traits]
version = "0.2.2"
version = "0.2.15"
default-features = false
# std or libm required for mul_add.
features = ["libm"]

[dependencies.quick-error]
version = "2.0.0"
Expand Down
2 changes: 2 additions & 0 deletions proptest/src/num/float_samplers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ macro_rules! float_sampler {
use rand::distributions::uniform::{
SampleBorrow, SampleUniform, Uniform, UniformSampler,
};
#[cfg(not(feature = "std"))]
use num_traits::float::Float;

#[must_use]
// Returns the previous float value. In other words the greatest value representable
Expand Down

0 comments on commit 1ccc872

Please sign in to comment.