]>
Commit | Line | Data |
---|---|---|
f20569fa | 1 | error: `Vec<T>` is already on the heap, the boxing is unnecessary |
cdc7bbd5 | 2 | --> $DIR/vec_box_sized.rs:12:14 |
f20569fa | 3 | | |
cdc7bbd5 XL |
4 | LL | const C: Vec<Box<i32>> = Vec::new(); |
5 | | ^^^^^^^^^^^^^ help: try: `Vec<i32>` | |
f20569fa XL |
6 | | |
7 | = note: `-D clippy::vec-box` implied by `-D warnings` | |
8 | ||
9 | error: `Vec<T>` is already on the heap, the boxing is unnecessary | |
cdc7bbd5 XL |
10 | --> $DIR/vec_box_sized.rs:13:15 |
11 | | | |
12 | LL | static S: Vec<Box<i32>> = Vec::new(); | |
13 | | ^^^^^^^^^^^^^ help: try: `Vec<i32>` | |
14 | ||
15 | error: `Vec<T>` is already on the heap, the boxing is unnecessary | |
16 | --> $DIR/vec_box_sized.rs:16:21 | |
17 | | | |
18 | LL | sized_type: Vec<Box<SizedStruct>>, | |
19 | | ^^^^^^^^^^^^^^^^^^^^^ help: try: `Vec<SizedStruct>` | |
20 | ||
21 | error: `Vec<T>` is already on the heap, the boxing is unnecessary | |
22 | --> $DIR/vec_box_sized.rs:19:14 | |
f20569fa XL |
23 | | |
24 | LL | struct A(Vec<Box<SizedStruct>>); | |
25 | | ^^^^^^^^^^^^^^^^^^^^^ help: try: `Vec<SizedStruct>` | |
26 | ||
27 | error: `Vec<T>` is already on the heap, the boxing is unnecessary | |
cdc7bbd5 | 28 | --> $DIR/vec_box_sized.rs:20:18 |
f20569fa XL |
29 | | |
30 | LL | struct B(Vec<Vec<Box<(u32)>>>); | |
31 | | ^^^^^^^^^^^^^^^ help: try: `Vec<u32>` | |
32 | ||
33 | error: `Vec<T>` is already on the heap, the boxing is unnecessary | |
cdc7bbd5 | 34 | --> $DIR/vec_box_sized.rs:48:23 |
f20569fa XL |
35 | | |
36 | LL | pub fn f() -> Vec<Box<S>> { | |
37 | | ^^^^^^^^^^^ help: try: `Vec<S>` | |
38 | ||
cdc7bbd5 | 39 | error: aborting due to 6 previous errors |
f20569fa | 40 |