]> git.lizzy.rs Git - rust.git/blob - tests/ui/bytes_nth.stderr
Addition `manual_map` test for `unsafe` blocks
[rust.git] / tests / ui / bytes_nth.stderr
1 error: called `.byte().nth()` on a `String`
2   --> $DIR/bytes_nth.rs:8:5
3    |
4 LL |     s.bytes().nth(3);
5    |     ^^^^^^^^^^^^^^^^ help: try: `s.as_bytes().get(3)`
6    |
7    = note: `-D clippy::bytes-nth` implied by `-D warnings`
8
9 error: called `.byte().nth()` on a `String`
10   --> $DIR/bytes_nth.rs:9:14
11    |
12 LL |     let _ = &s.bytes().nth(3);
13    |              ^^^^^^^^^^^^^^^^ help: try: `s.as_bytes().get(3)`
14
15 error: called `.byte().nth()` on a `str`
16   --> $DIR/bytes_nth.rs:10:5
17    |
18 LL |     s[..].bytes().nth(3);
19    |     ^^^^^^^^^^^^^^^^^^^^ help: try: `s[..].as_bytes().get(3)`
20
21 error: aborting due to 3 previous errors
22