src/nalgebra_support.rs

branch
dev
changeset 162
bea0c3841ced
parent 160
e7920e205785
child 164
fd9dba51afd3
--- a/src/nalgebra_support.rs	Tue Sep 02 15:18:30 2025 -0500
+++ b/src/nalgebra_support.rs	Wed Sep 03 09:16:03 2025 -0500
@@ -9,7 +9,7 @@
 */
 
 use crate::euclidean::*;
-use crate::instance::{Decomposition, Instance, Ownable, Space};
+use crate::instance::{Decomposition, Instance, MyCow, Ownable, Space};
 use crate::linops::*;
 use crate::norms::*;
 use crate::types::Float;
@@ -43,6 +43,14 @@
     fn clone_owned(&self) -> Self::OwnedVariant {
         Matrix::clone_owned(self)
     }
+
+    fn cow_owned<'b>(self) -> MyCow<'b, Self::OwnedVariant>
+    where
+        Self: 'b,
+    {
+        todo!()
+        //MyCow::owned(self.into_owned())
+    }
 }
 
 trait StridesOk<E, N, M = U1, S = <DefaultAllocator as Allocator<N, M>>::Buffer<E>>:
@@ -103,8 +111,6 @@
     DefaultAllocator: Allocator<M, K>,
     ShapeConstraint: StridesOk<E, M, K, S> + StridesOk<E, M, K>,
 {
-    type OwnedInstance = OMatrix<E, M, K>;
-
     type Decomposition<'b>
         = OMatrix<E, M, K>
     where

mercurial