mirror of
https://github.com/sharkdp/hyperfine.git
synced 2026-11-01 08:50:19 +00:00
New parameter module
This commit is contained in:
1 parent
865290a144
commit
47091a5740
7 files changed
+43
-40
No files matched your search
@@ -0,0 +1,19 @@
|
||||
use crate::numeric::NumericType;
|
||||
|
||||
pub mod range;
|
||||
pub mod tokenize;
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub enum ParameterValue {
|
||||
Text(String),
|
||||
Numeric(NumericType),
|
||||
}
|
||||
|
||||
impl<'a> ToString for ParameterValue {
|
||||
fn to_string(&self) -> String {
|
||||
match self {
|
||||
ParameterValue::Text(ref value) => value.clone(),
|
||||
ParameterValue::Numeric(value) => value.to_string(),
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user