error: usage of `Box>` --> $DIR/redundant_allocation.rs:16:30 | LL | pub fn box_test6(foo: Box>) {} | ^^^^^^^^^^ | = note: `Rc` is already on the heap, `Box>` makes an extra allocation = help: consider using just `Box` or `Rc` = note: `-D clippy::redundant-allocation` implied by `-D warnings` error: usage of `Box>` --> $DIR/redundant_allocation.rs:18:30 | LL | pub fn box_test7(foo: Box>) {} | ^^^^^^^^^^^ | = note: `Arc` is already on the heap, `Box>` makes an extra allocation = help: consider using just `Box` or `Arc` error: usage of `Box>>` --> $DIR/redundant_allocation.rs:20:27 | LL | pub fn box_test8() -> Box>> { | ^^^^^^^^^^^^^^^^^^^^ | = note: `Rc>` is already on the heap, `Box>>` makes an extra allocation = help: consider using just `Box>` or `Rc>` error: usage of `Box>` --> $DIR/redundant_allocation.rs:24:30 | LL | pub fn box_test9(foo: Box>) -> Box>> { | ^^^^^^^^^^^ | = note: `Arc` is already on the heap, `Box>` makes an extra allocation = help: consider using just `Box` or `Arc` error: usage of `Box>>` --> $DIR/redundant_allocation.rs:24:46 | LL | pub fn box_test9(foo: Box>) -> Box>> { | ^^^^^^^^^^^^^^^^^ | = note: `Arc>` is already on the heap, `Box>>` makes an extra allocation = help: consider using just `Box>` or `Arc>` error: usage of `Rc>` --> $DIR/redundant_allocation.rs:35:24 | LL | pub fn rc_test5(a: Rc>) {} | ^^^^^^^^^^^^^ | = note: `Box` is already on the heap, `Rc>` makes an extra allocation = help: consider using just `Rc` or `Box` error: usage of `Rc>` --> $DIR/redundant_allocation.rs:37:24 | LL | pub fn rc_test7(a: Rc>) {} | ^^^^^^^^^^^^^ | = note: `Arc` is already on the heap, `Rc>` makes an extra allocation = help: consider using just `Rc` or `Arc` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:39:26 | LL | pub fn rc_test8() -> Rc>> { | ^^^^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Box>` error: usage of `Rc>` --> $DIR/redundant_allocation.rs:43:29 | LL | pub fn rc_test9(foo: Rc>) -> Rc>> { | ^^^^^^^^^^ | = note: `Arc` is already on the heap, `Rc>` makes an extra allocation = help: consider using just `Rc` or `Arc` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:43:44 | LL | pub fn rc_test9(foo: Rc>) -> Rc>> { | ^^^^^^^^^^^^^^^^ | = note: `Arc>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Arc>` error: usage of `Arc>` --> $DIR/redundant_allocation.rs:54:25 | LL | pub fn arc_test5(a: Arc>) {} | ^^^^^^^^^^^^^^ | = note: `Box` is already on the heap, `Arc>` makes an extra allocation = help: consider using just `Arc` or `Box` error: usage of `Arc>` --> $DIR/redundant_allocation.rs:56:25 | LL | pub fn arc_test6(a: Arc>) {} | ^^^^^^^^^^^^^ | = note: `Rc` is already on the heap, `Arc>` makes an extra allocation = help: consider using just `Arc` or `Rc` error: usage of `Arc>>` --> $DIR/redundant_allocation.rs:58:27 | LL | pub fn arc_test8() -> Arc>> { | ^^^^^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Arc>>` makes an extra allocation = help: consider using just `Arc>` or `Box>` error: usage of `Arc>` --> $DIR/redundant_allocation.rs:62:30 | LL | pub fn arc_test9(foo: Arc>) -> Arc>> { | ^^^^^^^^^^ | = note: `Rc` is already on the heap, `Arc>` makes an extra allocation = help: consider using just `Arc` or `Rc` error: usage of `Arc>>` --> $DIR/redundant_allocation.rs:62:45 | LL | pub fn arc_test9(foo: Arc>) -> Arc>> { | ^^^^^^^^^^^^^^^^ | = note: `Rc>` is already on the heap, `Arc>>` makes an extra allocation = help: consider using just `Arc>` or `Rc>` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:84:27 | LL | pub fn test_rc_box(_: Rc>>) {} | ^^^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Box>` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:116:31 | LL | pub fn test_rc_box_str(_: Rc>>) {} | ^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Box>` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:117:33 | LL | pub fn test_rc_box_slice(_: Rc>>) {} | ^^^^^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Box>` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:118:32 | LL | pub fn test_rc_box_path(_: Rc>>) {} | ^^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Box>` error: usage of `Rc>>` --> $DIR/redundant_allocation.rs:119:34 | LL | pub fn test_rc_box_custom(_: Rc>>) {} | ^^^^^^^^^^^^^^^^^^^^^^ | = note: `Box>` is already on the heap, `Rc>>` makes an extra allocation = help: consider using just `Rc>` or `Box>` error: aborting due to 20 previous errors