mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
stopwatch: auto_start option, make pause cumulative
This commit is contained in:
@ -70,14 +70,14 @@ pub mut:
|
||||
|
||||
pub fn new_benchmark() Benchmark {
|
||||
return Benchmark{
|
||||
bench_timer: time.new_stopwatch()
|
||||
bench_timer: time.new_stopwatch({})
|
||||
verbose: true
|
||||
}
|
||||
}
|
||||
|
||||
pub fn new_benchmark_no_cstep() Benchmark {
|
||||
return Benchmark{
|
||||
bench_timer: time.new_stopwatch()
|
||||
bench_timer: time.new_stopwatch({})
|
||||
verbose: true
|
||||
no_cstep: true
|
||||
}
|
||||
@ -85,7 +85,7 @@ pub fn new_benchmark_no_cstep() Benchmark {
|
||||
|
||||
pub fn new_benchmark_pointer() &Benchmark {
|
||||
return &Benchmark{
|
||||
bench_timer: time.new_stopwatch()
|
||||
bench_timer: time.new_stopwatch({})
|
||||
verbose: true
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user