File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
crates/criterion_compat/src/compat Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -2,16 +2,19 @@ use std::marker::PhantomData;
2
2
use std:: { cell:: RefCell , rc:: Rc , time:: Duration } ;
3
3
4
4
use codspeed:: { codspeed:: CodSpeed , utils:: get_git_relative_path} ;
5
+ use criterion:: measurement:: WallTime ;
5
6
use criterion:: { measurement:: Measurement , PlotConfiguration , SamplingMode , Throughput } ;
6
7
7
8
use crate :: { Bencher , Criterion } ;
8
9
9
- pub struct BenchmarkGroup < M : Measurement > {
10
+ /// Deprecated: using the default measurement will be removed in the next major version.
11
+ /// Defaulting to WallTime differs from the original BenchmarkGroup implementation but avoids creating a breaking change
12
+ pub struct BenchmarkGroup < M : Measurement = WallTime > {
10
13
codspeed : Rc < RefCell < CodSpeed > > ,
11
14
current_file : String ,
12
15
macro_group : String ,
13
16
group_name : String ,
14
- phantom : PhantomData < * const M > ,
17
+ _marker : PhantomData < * const M > ,
15
18
}
16
19
17
20
impl < M : Measurement > BenchmarkGroup < M > {
@@ -25,7 +28,7 @@ impl<M: Measurement> BenchmarkGroup<M> {
25
28
current_file : criterion. current_file . clone ( ) ,
26
29
macro_group : criterion. macro_group . clone ( ) ,
27
30
group_name,
28
- phantom : PhantomData ,
31
+ _marker : PhantomData ,
29
32
}
30
33
}
31
34
You can’t perform that action at this time.
0 commit comments