|
1 | 1 | error: field assignment outside of initializer for an instance created with Default::default()
|
2 |
| - --> $DIR/field_reassign_with_default.rs:48:5 |
| 2 | + --> $DIR/field_reassign_with_default.rs:63:5 |
3 | 3 | |
|
4 | 4 | LL | a.i = 42;
|
5 | 5 | | ^^^^^^^^^
|
6 | 6 | |
|
7 | 7 | = note: `-D clippy::field-reassign-with-default` implied by `-D warnings`
|
8 | 8 | note: consider initializing the variable with `main::A { i: 42, ..Default::default() }` and removing relevant reassignments
|
9 |
| - --> $DIR/field_reassign_with_default.rs:47:5 |
| 9 | + --> $DIR/field_reassign_with_default.rs:62:5 |
10 | 10 | |
|
11 | 11 | LL | let mut a: A = Default::default();
|
12 | 12 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
13 | 13 |
|
14 | 14 | error: field assignment outside of initializer for an instance created with Default::default()
|
15 |
| - --> $DIR/field_reassign_with_default.rs:88:5 |
| 15 | + --> $DIR/field_reassign_with_default.rs:103:5 |
16 | 16 | |
|
17 | 17 | LL | a.j = 43;
|
18 | 18 | | ^^^^^^^^^
|
19 | 19 | |
|
20 | 20 | note: consider initializing the variable with `main::A { j: 43, i: 42 }` and removing relevant reassignments
|
21 |
| - --> $DIR/field_reassign_with_default.rs:87:5 |
| 21 | + --> $DIR/field_reassign_with_default.rs:102:5 |
22 | 22 | |
|
23 | 23 | LL | let mut a: A = Default::default();
|
24 | 24 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
25 | 25 |
|
26 | 26 | error: field assignment outside of initializer for an instance created with Default::default()
|
27 |
| - --> $DIR/field_reassign_with_default.rs:93:5 |
| 27 | + --> $DIR/field_reassign_with_default.rs:108:5 |
28 | 28 | |
|
29 | 29 | LL | a.i = 42;
|
30 | 30 | | ^^^^^^^^^
|
31 | 31 | |
|
32 | 32 | note: consider initializing the variable with `main::A { i: 42, j: 44 }` and removing relevant reassignments
|
33 |
| - --> $DIR/field_reassign_with_default.rs:92:5 |
| 33 | + --> $DIR/field_reassign_with_default.rs:107:5 |
34 | 34 | |
|
35 | 35 | LL | let mut a: A = Default::default();
|
36 | 36 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
37 | 37 |
|
38 | 38 | error: field assignment outside of initializer for an instance created with Default::default()
|
39 |
| - --> $DIR/field_reassign_with_default.rs:99:5 |
| 39 | + --> $DIR/field_reassign_with_default.rs:114:5 |
40 | 40 | |
|
41 | 41 | LL | a.i = 42;
|
42 | 42 | | ^^^^^^^^^
|
43 | 43 | |
|
44 | 44 | note: consider initializing the variable with `main::A { i: 42, ..Default::default() }` and removing relevant reassignments
|
45 |
| - --> $DIR/field_reassign_with_default.rs:98:5 |
| 45 | + --> $DIR/field_reassign_with_default.rs:113:5 |
46 | 46 | |
|
47 | 47 | LL | let mut a = A::default();
|
48 | 48 | | ^^^^^^^^^^^^^^^^^^^^^^^^^
|
49 | 49 |
|
50 | 50 | error: field assignment outside of initializer for an instance created with Default::default()
|
51 |
| - --> $DIR/field_reassign_with_default.rs:109:5 |
| 51 | + --> $DIR/field_reassign_with_default.rs:124:5 |
52 | 52 | |
|
53 | 53 | LL | a.i = Default::default();
|
54 | 54 | | ^^^^^^^^^^^^^^^^^^^^^^^^^
|
55 | 55 | |
|
56 | 56 | note: consider initializing the variable with `main::A { i: Default::default(), ..Default::default() }` and removing relevant reassignments
|
57 |
| - --> $DIR/field_reassign_with_default.rs:108:5 |
| 57 | + --> $DIR/field_reassign_with_default.rs:123:5 |
58 | 58 | |
|
59 | 59 | LL | let mut a: A = Default::default();
|
60 | 60 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
61 | 61 |
|
62 | 62 | error: field assignment outside of initializer for an instance created with Default::default()
|
63 |
| - --> $DIR/field_reassign_with_default.rs:113:5 |
| 63 | + --> $DIR/field_reassign_with_default.rs:128:5 |
64 | 64 | |
|
65 | 65 | LL | a.i = Default::default();
|
66 | 66 | | ^^^^^^^^^^^^^^^^^^^^^^^^^
|
67 | 67 | |
|
68 | 68 | note: consider initializing the variable with `main::A { i: Default::default(), j: 45 }` and removing relevant reassignments
|
69 |
| - --> $DIR/field_reassign_with_default.rs:112:5 |
| 69 | + --> $DIR/field_reassign_with_default.rs:127:5 |
70 | 70 | |
|
71 | 71 | LL | let mut a: A = Default::default();
|
72 | 72 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
73 | 73 |
|
74 | 74 | error: field assignment outside of initializer for an instance created with Default::default()
|
75 |
| - --> $DIR/field_reassign_with_default.rs:135:5 |
| 75 | + --> $DIR/field_reassign_with_default.rs:150:5 |
76 | 76 | |
|
77 | 77 | LL | a.i = vec![1];
|
78 | 78 | | ^^^^^^^^^^^^^^
|
79 | 79 | |
|
80 | 80 | note: consider initializing the variable with `C { i: vec![1], ..Default::default() }` and removing relevant reassignments
|
81 |
| - --> $DIR/field_reassign_with_default.rs:134:5 |
| 81 | + --> $DIR/field_reassign_with_default.rs:149:5 |
82 | 82 | |
|
83 | 83 | LL | let mut a: C = C::default();
|
84 | 84 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
85 | 85 |
|
86 | 86 | error: field assignment outside of initializer for an instance created with Default::default()
|
87 |
| - --> $DIR/field_reassign_with_default.rs:142:5 |
| 87 | + --> $DIR/field_reassign_with_default.rs:157:5 |
88 | 88 | |
|
89 | 89 | LL | a.i = true;
|
90 | 90 | | ^^^^^^^^^^^
|
91 | 91 | |
|
92 | 92 | note: consider initializing the variable with `Wrapper::<bool> { i: true }` and removing relevant reassignments
|
93 |
| - --> $DIR/field_reassign_with_default.rs:141:5 |
| 93 | + --> $DIR/field_reassign_with_default.rs:156:5 |
94 | 94 | |
|
95 | 95 | LL | let mut a: Wrapper<bool> = Default::default();
|
96 | 96 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
97 | 97 |
|
98 | 98 | error: field assignment outside of initializer for an instance created with Default::default()
|
99 |
| - --> $DIR/field_reassign_with_default.rs:145:5 |
| 99 | + --> $DIR/field_reassign_with_default.rs:160:5 |
100 | 100 | |
|
101 | 101 | LL | a.i = 42;
|
102 | 102 | | ^^^^^^^^^
|
103 | 103 | |
|
104 | 104 | note: consider initializing the variable with `WrapperMulti::<i32, i64> { i: 42, ..Default::default() }` and removing relevant reassignments
|
105 |
| - --> $DIR/field_reassign_with_default.rs:144:5 |
| 105 | + --> $DIR/field_reassign_with_default.rs:159:5 |
106 | 106 | |
|
107 | 107 | LL | let mut a: WrapperMulti<i32, i64> = Default::default();
|
108 | 108 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
0 commit comments