Skip to content

Commit 139e898

Browse files
committed
Zipf: Simplify trait bounds
1 parent 4d67af2 commit 139e898

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

rand_distr/src/zipf.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ where F: Float, Standard: Distribution<F>, OpenClosed01: Distribution<F>
110110
/// ```
111111
#[derive(Clone, Copy, Debug)]
112112
pub struct Zipf<F>
113-
where F: Float, Standard: Distribution<F>, OpenClosed01: Distribution<F> {
113+
where F: Float, Standard: Distribution<F> {
114114
n: F,
115115
s: F,
116116
t: F,
@@ -139,7 +139,7 @@ impl fmt::Display for ZipfError {
139139
impl std::error::Error for ZipfError {}
140140

141141
impl<F> Zipf<F>
142-
where F: Float, Standard: Distribution<F>, OpenClosed01: Distribution<F> {
142+
where F: Float, Standard: Distribution<F> {
143143
/// Construct a new `Zipf` distribution for a set with `n` elements and a
144144
/// frequency rank exponent `s`.
145145
///
@@ -179,7 +179,7 @@ where F: Float, Standard: Distribution<F>, OpenClosed01: Distribution<F> {
179179
}
180180

181181
impl<F> Distribution<F> for Zipf<F>
182-
where F: Float, Standard: Distribution<F>, OpenClosed01: Distribution<F>
182+
where F: Float, Standard: Distribution<F>
183183
{
184184
#[inline]
185185
fn sample<R: Rng + ?Sized>(&self, rng: &mut R) -> F {

0 commit comments

Comments
 (0)