1 error: this expression borrows a reference that is immediately dereferenced by the compiler
2 --> $DIR/needless_borrow.rs:13:15
7 = note: #[deny(needless_borrow)] implied by #[deny(clippy)]
8 note: lint level defined here
9 --> $DIR/needless_borrow.rs:8:8
14 error: this pattern creates a reference to a reference
15 --> $DIR/needless_borrow.rs:20:17
17 20 | if let Some(ref cake) = Some(&5) {}
20 = note: #[deny(needless_borrow)] implied by #[deny(clippy)]
22 error: this expression borrows a reference that is immediately dereferenced by the compiler
23 --> $DIR/needless_borrow.rs:27:15
28 = note: #[deny(needless_borrow)] implied by #[deny(clippy)]
30 warning: this pattern creates a reference to a reference
31 --> $DIR/needless_borrow.rs:50:31
33 50 | let _ = v.iter().filter(|&ref a| a.is_empty());
36 = note: #[warn(needless_borrow)] on by default
38 error: aborting due to 3 previous errors