]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/iter_next_slice.stderr
Auto merge of #84620 - Dylan-DPC:rollup-wkv97im, r=Dylan-DPC
[rust.git] / src / tools / clippy / tests / ui / iter_next_slice.stderr
1 error: using `.iter().next()` on an array
2   --> $DIR/iter_next_slice.rs:9:5
3    |
4 LL |     s.iter().next();
5    |     ^^^^^^^^^^^^^^^ help: try calling: `s.get(0)`
6    |
7    = note: `-D clippy::iter-next-slice` implied by `-D warnings`
8
9 error: using `.iter().next()` on a Slice without end index
10   --> $DIR/iter_next_slice.rs:12:5
11    |
12 LL |     s[2..].iter().next();
13    |     ^^^^^^^^^^^^^^^^^^^^ help: try calling: `s.get(2)`
14
15 error: using `.iter().next()` on a Slice without end index
16   --> $DIR/iter_next_slice.rs:15:5
17    |
18 LL |     v[5..].iter().next();
19    |     ^^^^^^^^^^^^^^^^^^^^ help: try calling: `v.get(5)`
20
21 error: using `.iter().next()` on an array
22   --> $DIR/iter_next_slice.rs:18:5
23    |
24 LL |     v.iter().next();
25    |     ^^^^^^^^^^^^^^^ help: try calling: `v.get(0)`
26
27 error: aborting due to 4 previous errors
28