diff --git a/resources/weight_analyzer/src/lib.rs b/resources/weight_analyzer/src/lib.rs index d4c3756d017f782f0c50285034cb832ec0f0ba05..afc0879280e3910806a5237f1e1a9b1d087df838 100644 --- a/resources/weight_analyzer/src/lib.rs +++ b/resources/weight_analyzer/src/lib.rs @@ -24,8 +24,8 @@ impl Div<&MaxBlockWeight> for f64 { } } impl MaxBlockWeight { - pub fn new(value: f64) -> Self { - MaxBlockWeight(value) + pub fn new<T: Into<f64>>(value: T) -> Self { + MaxBlockWeight(value.into()) } }