Skip to content

Commit b43d7b0

Browse files
committed
Generalize stats from f64 to the Float trait
1 parent 3a321b0 commit b43d7b0

File tree

2 files changed

+116
-98
lines changed

2 files changed

+116
-98
lines changed

src/libtest/lib.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ pub fn opt_shard(maybestr: Option<~str>) -> Option<(uint,uint)> {
413413

414414
#[deriving(Clone, Eq)]
415415
pub struct BenchSamples {
416-
ns_iter_summ: stats::Summary,
416+
ns_iter_summ: stats::Summary<f64>,
417417
mb_s: uint,
418418
}
419419

@@ -1249,7 +1249,7 @@ impl Bencher {
12491249
}
12501250

12511251
// This is a more statistics-driven benchmark algorithm
1252-
pub fn auto_bench(&mut self, f: |&mut Bencher|) -> stats::Summary {
1252+
pub fn auto_bench(&mut self, f: |&mut Bencher|) -> stats::Summary<f64> {
12531253

12541254
// Initial bench run to get ballpark figure.
12551255
let mut n = 1_u64;

0 commit comments

Comments
 (0)