Skip to content
Myr

Rename num

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by David Peter · committed by David Peter · parent fa2eaaa · Browse files · 1 file+5 added−5 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+5 added−5 removed

  • other:+5 added−5 removed

1 file+5 added−5 removed

modified:src/benchmark/scheduler.rs+5 added-5 removed
179 unmodified lines
180 self.options.output_style,181 self.options.command_output_policy,182 )?;183184 for (num, cmd) in self.commands.iter().enumerate() {184 for (benchmark_number, cmd) in self.commands.iter().enumerate() {185 self.results186 .push(self.run_benchmark(num, cmd, shell_spawning_time)?);186 .push(self.run_benchmark(benchmark_number, cmd, shell_spawning_time)?);187188 // We export (all results so far) after each individual benchmark, because189 // we would risk losing all results if a later benchmark fails.190 self.export_manager
112 unmodified lines
303304 /// Run the benchmark for a single shell command305 pub fn run_benchmark(306 &self,307 num: usize,307 benchmark_number: usize,308 cmd: &Command<'_>,309 shell_spawning_time: TimingResult,310 ) -> Result<BenchmarkResult> {311 let command_name = cmd.get_name();312 if self.options.output_style != OutputStyleOption::Disabled {313 println!(314 "{}{}: {}",315 "Benchmark ".bold(),316 (num + 1).to_string().bold(),316 (benchmark_number + 1).to_string().bold(),317 command_name,318 );319 }320
6 unmodified lines
327 let prepare_cmd = self.options.preparation_command.as_ref().map(|values| {328 let preparation_command = if values.len() == 1 {329 &values[0]330 } else {331 &values[num]331 &values[benchmark_number]332 };333 Command::new_parametrized(334 None,335 preparation_command,
243 unmodified lines