Skip to content

Commit

Permalink
Merge pull request #11 from kornelski/dep
Browse files Browse the repository at this point in the history
Upgrade rand
  • Loading branch information
sile committed Jan 13, 2021
2 parents c8a0735 + b8d2171 commit f3798f4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,5 @@ default = [ "stacktrace" ]
[dependencies]
backtrace = { version = "0.3", optional = true }
crossbeam-channel = "0.5"
rand = "0.7"
rand = "0.8.1"
trackable = "0.2"
2 changes: 1 addition & 1 deletion src/sampler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ impl ProbabilisticSampler {
}
impl<T> Sampler<T> for ProbabilisticSampler {
fn is_sampled(&self, _span: &CandidateSpan<T>) -> bool {
rand::thread_rng().gen_range(0.0, 1.0) < self.sampling_rate
rand::thread_rng().gen_range(0.0..1.0) < self.sampling_rate
}
}

Expand Down

0 comments on commit f3798f4

Please sign in to comment.