- add __len__ to PyShape

This commit is contained in:
w.pomp
2026-07-22 17:31:36 +02:00
parent b063a63869
commit c16e71bf30
+4
View File
@@ -2025,6 +2025,10 @@ impl PyShape {
} }
} }
fn __len__(&self) -> usize {
self.inner.order.len()
}
fn to_list(&self) -> Vec<usize> { fn to_list(&self) -> Vec<usize> {
vec![ vec![
self.inner.c, self.inner.c,