From 7a031d54974f295f80933b7ba92de4bde7ae8930 Mon Sep 17 00:00:00 2001 From: Robert Bamler Date: Sun, 5 May 2024 13:07:32 +0200 Subject: [PATCH] Remove dead code found by new clippy lint --- src/pybindings/stream/model/internals.rs | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/pybindings/stream/model/internals.rs b/src/pybindings/stream/model/internals.rs index f88402a..aaa1d94 100644 --- a/src/pybindings/stream/model/internals.rs +++ b/src/pybindings/stream/model/internals.rs @@ -152,7 +152,6 @@ where trait ParameterExtract<'source, Target: numpy::Element + 'source> { type Extracted: pyo3::FromPyObject<'source> + 'source; fn cast(param: &Self::Extracted) -> PyResult>>; - fn len(param: &'source PyAny) -> PyResult; } struct ParameterExtractor(PhantomData); @@ -163,10 +162,6 @@ impl<'source> ParameterExtract<'source, i32> for ParameterExtractor { fn cast(param: &Self::Extracted) -> PyResult>> { Ok(Cow::Borrowed(param)) } - - fn len(param: &'source PyAny) -> PyResult { - Ok(param.extract::()?.len()) - } } impl<'source> ParameterExtract<'source, f64> for ParameterExtractor { @@ -175,10 +170,6 @@ impl<'source> ParameterExtract<'source, f64> for ParameterExtractor { fn cast(param: &Self::Extracted) -> PyResult>> { param.cast_f64() } - - fn len(param: &'source PyAny) -> PyResult { - Ok(param.extract::()?.len()) - } } macro_rules! impl_model_for_parameterizable_model {