]> git.lizzy.rs Git - rust.git/blob - tests/ui/no_effect_replace.stderr
Auto merge of #9684 - kraktus:ref_option_ref, r=xFrednet
[rust.git] / tests / ui / no_effect_replace.stderr
1 error: replacing text with itself
2   --> $DIR/no_effect_replace.rs:4:13
3    |
4 LL |     let _ = "12345".replace('1', "1");
5    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
6    |
7    = note: `-D clippy::no-effect-replace` implied by `-D warnings`
8
9 error: replacing text with itself
10   --> $DIR/no_effect_replace.rs:5:13
11    |
12 LL |     let _ = "12345".replace("12", "12");
13    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
14
15 error: replacing text with itself
16   --> $DIR/no_effect_replace.rs:6:13
17    |
18 LL |     let _ = String::new().replace("12", "12");
19    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
20
21 error: replacing text with itself
22   --> $DIR/no_effect_replace.rs:8:13
23    |
24 LL |     let _ = "12345".replacen('1', "1", 1);
25    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
26
27 error: replacing text with itself
28   --> $DIR/no_effect_replace.rs:9:13
29    |
30 LL |     let _ = "12345".replacen("12", "12", 1);
31    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
32
33 error: replacing text with itself
34   --> $DIR/no_effect_replace.rs:10:13
35    |
36 LL |     let _ = String::new().replacen("12", "12", 1);
37    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
38
39 error: replacing text with itself
40   --> $DIR/no_effect_replace.rs:16:13
41    |
42 LL |     let _ = "hello".replace(&x.f(), &x.f());
43    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
44
45 error: replacing text with itself
46   --> $DIR/no_effect_replace.rs:19:13
47    |
48 LL |     let _ = "hello".replace(&y(), &y());
49    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
50
51 error: aborting due to 8 previous errors
52