clippy
authorBen Pfaff <blp@cs.stanford.edu>
Sun, 13 Apr 2025 18:11:05 +0000 (11:11 -0700)
committerBen Pfaff <blp@cs.stanford.edu>
Sun, 13 Apr 2025 18:11:05 +0000 (11:11 -0700)
rust/pspp/src/output/pivot/mod.rs

index 2e972dc104fd5d11bfba98c52e6efc997ee8b7dd..cd6e28f80c4fa8df3d8b8ace7206a0822620ad9d 100644 (file)
@@ -522,7 +522,7 @@ impl Category {
             Category::Group(group) => group.nth_leaf(index),
             Category::Leaf(leaf) => {
                 if index == 0 {
-                    Some(&leaf)
+                    Some(leaf)
                 } else {
                     None
                 }
@@ -535,10 +535,7 @@ impl Category {
             Category::Group(group) => group.leaf_path(index, groups),
             Category::Leaf(leaf) => {
                 if index == 0 {
-                    Some(Path {
-                        groups,
-                        leaf: &leaf,
-                    })
+                    Some(Path { groups, leaf })
                 } else {
                     None
                 }