@@ -122,7 +122,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
122
122
--> tests/ui/useless_conversion.rs:189:7
123
123
|
124
124
LL | b(vec![1, 2].into_iter());
125
- | ^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `vec![1, 2]`
125
+ | ^^^^^^^^^^------------
126
+ | |
127
+ | help: consider removing the `.into_iter()`
126
128
|
127
129
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
128
130
--> tests/ui/useless_conversion.rs:179:13
@@ -134,7 +136,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
134
136
--> tests/ui/useless_conversion.rs:190:7
135
137
|
136
138
LL | c(vec![1, 2].into_iter());
137
- | ^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `vec![1, 2]`
139
+ | ^^^^^^^^^^------------
140
+ | |
141
+ | help: consider removing the `.into_iter()`
138
142
|
139
143
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
140
144
--> tests/ui/useless_conversion.rs:180:18
@@ -146,7 +150,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
146
150
--> tests/ui/useless_conversion.rs:191:7
147
151
|
148
152
LL | d(vec![1, 2].into_iter());
149
- | ^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `vec![1, 2]`
153
+ | ^^^^^^^^^^------------
154
+ | |
155
+ | help: consider removing the `.into_iter()`
150
156
|
151
157
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
152
158
--> tests/ui/useless_conversion.rs:183:12
@@ -158,7 +164,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
158
164
--> tests/ui/useless_conversion.rs:194:7
159
165
|
160
166
LL | b(vec![1, 2].into_iter().into_iter());
161
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`s: `vec![1, 2]`
167
+ | ^^^^^^^^^^------------------------
168
+ | |
169
+ | help: consider removing the `.into_iter()`s
162
170
|
163
171
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
164
172
--> tests/ui/useless_conversion.rs:179:13
@@ -170,7 +178,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
170
178
--> tests/ui/useless_conversion.rs:195:7
171
179
|
172
180
LL | b(vec![1, 2].into_iter().into_iter().into_iter());
173
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`s: `vec![1, 2]`
181
+ | ^^^^^^^^^^------------------------------------
182
+ | |
183
+ | help: consider removing the `.into_iter()`s
174
184
|
175
185
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
176
186
--> tests/ui/useless_conversion.rs:179:13
@@ -182,7 +192,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
182
192
--> tests/ui/useless_conversion.rs:241:24
183
193
|
184
194
LL | foo2::<i32, _>([1, 2, 3].into_iter());
185
- | ^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `[1, 2, 3]`
195
+ | ^^^^^^^^^------------
196
+ | |
197
+ | help: consider removing the `.into_iter()`
186
198
|
187
199
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
188
200
--> tests/ui/useless_conversion.rs:220:12
@@ -194,7 +206,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
194
206
--> tests/ui/useless_conversion.rs:249:14
195
207
|
196
208
LL | foo3([1, 2, 3].into_iter());
197
- | ^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `[1, 2, 3]`
209
+ | ^^^^^^^^^------------
210
+ | |
211
+ | help: consider removing the `.into_iter()`
198
212
|
199
213
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
200
214
--> tests/ui/useless_conversion.rs:229:12
@@ -206,7 +220,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
206
220
--> tests/ui/useless_conversion.rs:258:16
207
221
|
208
222
LL | S1.foo([1, 2].into_iter());
209
- | ^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `[1, 2]`
223
+ | ^^^^^^------------
224
+ | |
225
+ | help: consider removing the `.into_iter()`
210
226
|
211
227
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
212
228
--> tests/ui/useless_conversion.rs:255:27
@@ -218,7 +234,9 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
218
234
--> tests/ui/useless_conversion.rs:277:44
219
235
|
220
236
LL | v0.into_iter().interleave_shortest(v1.into_iter());
221
- | ^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `v1`
237
+ | ^^------------
238
+ | |
239
+ | help: consider removing the `.into_iter()`
222
240
|
223
241
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
224
242
--> tests/ui/useless_conversion.rs:264:20
@@ -278,61 +296,86 @@ error: explicit call to `.into_iter()` in function argument accepting `IntoItera
278
296
--> tests/ui/useless_conversion.rs:358:29
279
297
|
280
298
LL | takes_into_iter(self.my_field.into_iter());
281
- | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `&self.my_field`
299
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^
282
300
|
283
301
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
284
302
--> tests/ui/useless_conversion.rs:347:32
285
303
|
286
304
LL | fn takes_into_iter(_: impl IntoIterator<Item = String>) {}
287
305
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
306
+ help: consider removing the `.into_iter()`
307
+ |
308
+ LL - takes_into_iter(self.my_field.into_iter());
309
+ LL + takes_into_iter(&self.my_field);
310
+ |
288
311
289
312
error: explicit call to `.into_iter()` in function argument accepting `IntoIterator`
290
313
--> tests/ui/useless_conversion.rs:366:29
291
314
|
292
315
LL | takes_into_iter(self.my_field.into_iter());
293
- | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `&mut self.my_field`
316
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^
294
317
|
295
318
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
296
319
--> tests/ui/useless_conversion.rs:347:32
297
320
|
298
321
LL | fn takes_into_iter(_: impl IntoIterator<Item = String>) {}
299
322
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
323
+ help: consider removing the `.into_iter()`
324
+ |
325
+ LL - takes_into_iter(self.my_field.into_iter());
326
+ LL + takes_into_iter(&mut self.my_field);
327
+ |
300
328
301
329
error: explicit call to `.into_iter()` in function argument accepting `IntoIterator`
302
330
--> tests/ui/useless_conversion.rs:375:29
303
331
|
304
332
LL | takes_into_iter(self.my_field.into_iter());
305
- | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `*self.my_field`
333
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^
306
334
|
307
335
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
308
336
--> tests/ui/useless_conversion.rs:347:32
309
337
|
310
338
LL | fn takes_into_iter(_: impl IntoIterator<Item = String>) {}
311
339
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
340
+ help: consider removing the `.into_iter()`
341
+ |
342
+ LL - takes_into_iter(self.my_field.into_iter());
343
+ LL + takes_into_iter(*self.my_field);
344
+ |
312
345
313
346
error: explicit call to `.into_iter()` in function argument accepting `IntoIterator`
314
347
--> tests/ui/useless_conversion.rs:384:29
315
348
|
316
349
LL | takes_into_iter(self.my_field.into_iter());
317
- | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `&*self.my_field`
350
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^
318
351
|
319
352
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
320
353
--> tests/ui/useless_conversion.rs:347:32
321
354
|
322
355
LL | fn takes_into_iter(_: impl IntoIterator<Item = String>) {}
323
356
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
357
+ help: consider removing the `.into_iter()`
358
+ |
359
+ LL - takes_into_iter(self.my_field.into_iter());
360
+ LL + takes_into_iter(&*self.my_field);
361
+ |
324
362
325
363
error: explicit call to `.into_iter()` in function argument accepting `IntoIterator`
326
364
--> tests/ui/useless_conversion.rs:393:29
327
365
|
328
366
LL | takes_into_iter(self.my_field.into_iter());
329
- | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing the `.into_iter()`: `&mut *self.my_field`
367
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^
330
368
|
331
369
note: this parameter accepts any `IntoIterator`, so you don't need to call `.into_iter()`
332
370
--> tests/ui/useless_conversion.rs:347:32
333
371
|
334
372
LL | fn takes_into_iter(_: impl IntoIterator<Item = String>) {}
335
373
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
374
+ help: consider removing the `.into_iter()`
375
+ |
376
+ LL - takes_into_iter(self.my_field.into_iter());
377
+ LL + takes_into_iter(&mut *self.my_field);
378
+ |
336
379
337
380
error: aborting due to 41 previous errors
338
381
0 commit comments