summaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
authorChristoph Groth <christoph.groth@cea.fr>2025-04-30 10:51:20 +0200
committerChristoph Groth <christoph.groth@cea.fr>2025-04-30 10:51:20 +0200
commit425adfa8e2afd903d3900b9d9562f380d54bd9b4 (patch)
tree415bb5da90d0fff293127420eebb0e6522595d1a /src/main.rs
parent3b17aec40c968a1f08bc102982b64aea34f10976 (diff)
Demonstrate reorder(=transpose)
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.rs b/src/main.rs
index 828654a..b64fb7b 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -35,8 +35,8 @@ fn main() {
// index
let _ = c[4];
- // permute
- let _ = c.permute([1, 0]);
+ // permute & transpose
+ assert_eq!(c.permute([1, 0]), c.reorder());
// Arrays with rank > 6:
let d: Vec<f64> = (0..128).map(|x| x as f64).collect();