1 error: mutable borrow from immutable input(s)
2 --> $DIR/mut_from_ref.rs:9:39
4 9 | fn this_wont_hurt_a_bit(&self) -> &mut Foo {
7 note: lint level defined here
8 --> $DIR/mut_from_ref.rs:4:9
10 4 | #![deny(mut_from_ref)]
12 note: immutable borrow here
13 --> $DIR/mut_from_ref.rs:9:29
15 9 | fn this_wont_hurt_a_bit(&self) -> &mut Foo {
18 error: mutable borrow from immutable input(s)
19 --> $DIR/mut_from_ref.rs:15:25
21 15 | fn ouch(x: &Foo) -> &mut Foo;
24 note: immutable borrow here
25 --> $DIR/mut_from_ref.rs:15:16
27 15 | fn ouch(x: &Foo) -> &mut Foo;
30 error: mutable borrow from immutable input(s)
31 --> $DIR/mut_from_ref.rs:24:21
33 24 | fn fail(x: &u32) -> &mut u16 {
36 note: immutable borrow here
37 --> $DIR/mut_from_ref.rs:24:12
39 24 | fn fail(x: &u32) -> &mut u16 {
42 error: mutable borrow from immutable input(s)
43 --> $DIR/mut_from_ref.rs:28:50
45 28 | fn fail_lifetime<'a>(x: &'a u32, y: &mut u32) -> &'a mut u32 {
48 note: immutable borrow here
49 --> $DIR/mut_from_ref.rs:28:25
51 28 | fn fail_lifetime<'a>(x: &'a u32, y: &mut u32) -> &'a mut u32 {
54 error: mutable borrow from immutable input(s)
55 --> $DIR/mut_from_ref.rs:32:67
57 32 | fn fail_double<'a, 'b>(x: &'a u32, y: &'a u32, z: &'b mut u32) -> &'a mut u32 {
60 note: immutable borrow here
61 --> $DIR/mut_from_ref.rs:32:27
63 32 | fn fail_double<'a, 'b>(x: &'a u32, y: &'a u32, z: &'b mut u32) -> &'a mut u32 {
66 error: aborting due to 5 previous errors