--- a/src/nalgebra_support.rs Tue Sep 02 00:09:46 2025 -0500 +++ b/src/nalgebra_support.rs Tue Sep 02 08:01:57 2025 -0500 @@ -59,11 +59,13 @@ #[derive(Copy, Clone, Debug)] pub struct MatrixDecomposition; -impl<E, M, K, S> Decomposition<Matrix<E, M, K, S>> for MatrixDecomposition +impl<E, M, K, S, RS, CS> Decomposition<Matrix<E, M, K, S>> for MatrixDecomposition where - S: Storage<E, M, K>, + S: Storage<E, M, K, RStride = RS, CStride = CS>, M: Dim, K: Dim, + RS: Dim, + CS: Dim, E: Scalar + Zero + One, DefaultAllocator: Allocator<M, K>, { @@ -74,19 +76,23 @@ where Matrix<E, M, K, S>: 'b; type Reference<'b> - = &'b MatrixView<'b, E, M, K, Dyn, Dyn> + = &'b MatrixView<'b, E, M, K, RS, CS> where Matrix<E, M, K, S>: 'b; #[inline] - fn lift<'b>(r: Self::Reference<'b>) -> Self::Decomposition<'b> { + fn lift<'b>(r: Self::Reference<'b>) -> Self::Decomposition<'b> + where + S: 'b, + { r.into_owned() } } -impl<SM, SV, M, K, E> Instance<Matrix<E, M, K, SM>> for Matrix<E, M, K, SV> +impl<S, SV, M, K, E, RS, CS> Instance<Matrix<E, M, K, S>, MatrixDecomposition> + for Matrix<E, M, K, SV> where - SM: Storage<E, M, K>, + S: Storage<E, M, K, RStride = RS, CStride = CS>, SV: Storage<E, M, K>, M: Dim, K: Dim, @@ -102,7 +108,7 @@ fn eval_ref_decompose<'b, R>( &'b self, - f: impl FnOnce(&'b MatrixView<'b, E, M, K, Dyn, Dyn>) -> R, + f: impl FnOnce(<MatrixDecomposition as Decomposition<Self>>::Reference<'b>) -> R, ) -> R where Self: 'b,