]> git.lizzy.rs Git - rust.git/blob - clippy_tests/examples/mut_from_ref.stderr
Fix the test suite after cargo update
[rust.git] / clippy_tests / examples / mut_from_ref.stderr
1 error: mutable borrow from immutable input(s)
2  --> mut_from_ref.rs:9:39
3   |
4 9 |     fn this_wont_hurt_a_bit(&self) -> &mut Foo {
5   |                                       ^^^^^^^^
6   |
7   = note: `-D mut-from-ref` implied by `-D warnings`
8 note: immutable borrow here
9  --> mut_from_ref.rs:9:29
10   |
11 9 |     fn this_wont_hurt_a_bit(&self) -> &mut Foo {
12   |                             ^^^^^
13
14 error: mutable borrow from immutable input(s)
15   --> mut_from_ref.rs:15:25
16    |
17 15 |     fn ouch(x: &Foo) -> &mut Foo;
18    |                         ^^^^^^^^
19    |
20    = note: `-D mut-from-ref` implied by `-D warnings`
21 note: immutable borrow here
22   --> mut_from_ref.rs:15:16
23    |
24 15 |     fn ouch(x: &Foo) -> &mut Foo;
25    |                ^^^^
26
27 error: mutable borrow from immutable input(s)
28   --> mut_from_ref.rs:24:21
29    |
30 24 | fn fail(x: &u32) -> &mut u16 {
31    |                     ^^^^^^^^
32    |
33    = note: `-D mut-from-ref` implied by `-D warnings`
34 note: immutable borrow here
35   --> mut_from_ref.rs:24:12
36    |
37 24 | fn fail(x: &u32) -> &mut u16 {
38    |            ^^^^
39
40 error: mutable borrow from immutable input(s)
41   --> mut_from_ref.rs:28:50
42    |
43 28 | fn fail_lifetime<'a>(x: &'a u32, y: &mut u32) -> &'a mut u32 {
44    |                                                  ^^^^^^^^^^^
45    |
46    = note: `-D mut-from-ref` implied by `-D warnings`
47 note: immutable borrow here
48   --> mut_from_ref.rs:28:25
49    |
50 28 | fn fail_lifetime<'a>(x: &'a u32, y: &mut u32) -> &'a mut u32 {
51    |                         ^^^^^^^
52
53 error: mutable borrow from immutable input(s)
54   --> mut_from_ref.rs:32:67
55    |
56 32 | fn fail_double<'a, 'b>(x: &'a u32, y: &'a u32, z: &'b mut u32) -> &'a mut u32 {
57    |                                                                   ^^^^^^^^^^^
58    |
59    = note: `-D mut-from-ref` implied by `-D warnings`
60 note: immutable borrow here
61   --> mut_from_ref.rs:32:27
62    |
63 32 | fn fail_double<'a, 'b>(x: &'a u32, y: &'a u32, z: &'b mut u32) -> &'a mut u32 {
64    |                           ^^^^^^^     ^^^^^^^
65
66 error: aborting due to previous error(s)
67
68
69 To learn more, run the command again with --verbose.