Add new (hidden) --min-benchmarking-time option

This commit is contained in:
David Peter authored and David Peter committed 2022-09-07 09:13:53 +02:00
1 parent 77e1b5e72f
commit dffbdc34d4
4 files changed
+24 -4

No files matched your search

+7 -1
View File
@@ -226,7 +226,7 @@ impl Options {
.value_of(param)
.map(|n| {
n.parse::<u64>()
.map_err(|e| OptionsError::NumericParsingError(param, e))
.map_err(|e| OptionsError::IntParsingError(param, e))
})
.transpose()
};
@@ -345,6 +345,12 @@ impl Options {
_ => None,
};
if let Some(time) = matches.value_of("min-benchmarking-time") {
options.min_benchmarking_time = time
.parse::<f64>()
.map_err(|e| OptionsError::FloatParsingError("min-benchmarking-time", e))?;
}
Ok(options)
}