]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/min_rust_version_attr.stderr
Auto merge of #91565 - dtolnay:printhelpers, r=jackh726
[rust.git] / src / tools / clippy / tests / ui / min_rust_version_attr.stderr
1 error: stripping a prefix manually
2   --> $DIR/min_rust_version_attr.rs:165:24
3    |
4 LL |             assert_eq!(s["hello, ".len()..].to_uppercase(), "WORLD!");
5    |                        ^^^^^^^^^^^^^^^^^^^^
6    |
7    = note: `-D clippy::manual-strip` implied by `-D warnings`
8 note: the prefix was tested here
9   --> $DIR/min_rust_version_attr.rs:164:9
10    |
11 LL |         if s.starts_with("hello, ") {
12    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
13 help: try using the `strip_prefix` method
14    |
15 LL ~         if let Some(<stripped>) = s.strip_prefix("hello, ") {
16 LL ~             assert_eq!(<stripped>.to_uppercase(), "WORLD!");
17    |
18
19 error: stripping a prefix manually
20   --> $DIR/min_rust_version_attr.rs:177:24
21    |
22 LL |             assert_eq!(s["hello, ".len()..].to_uppercase(), "WORLD!");
23    |                        ^^^^^^^^^^^^^^^^^^^^
24    |
25 note: the prefix was tested here
26   --> $DIR/min_rust_version_attr.rs:176:9
27    |
28 LL |         if s.starts_with("hello, ") {
29    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
30 help: try using the `strip_prefix` method
31    |
32 LL ~         if let Some(<stripped>) = s.strip_prefix("hello, ") {
33 LL ~             assert_eq!(<stripped>.to_uppercase(), "WORLD!");
34    |
35
36 error: aborting due to 2 previous errors
37