diff --git a/clippy_utils/src/check_proc_macro.rs b/clippy_utils/src/check_proc_macro.rs index 8a8ccc30205..e0dbc1c9701 100644 --- a/clippy_utils/src/check_proc_macro.rs +++ b/clippy_utils/src/check_proc_macro.rs @@ -344,7 +344,7 @@ impl<'cx> WithSearchPat for (&Attribute, &LateContext<'cx>) { type Context = LateContext<'cx>; fn search_pat(&self, _cx: &Self::Context) -> (Pat, Pat) { - attr_search_pat(&self.0) + attr_search_pat(self.0) } fn span(&self) -> Span { diff --git a/tests/ui/allow_attributes.fixed b/tests/ui/allow_attributes.fixed index be93c5bffe7..5c30a9d2941 100644 --- a/tests/ui/allow_attributes.fixed +++ b/tests/ui/allow_attributes.fixed @@ -25,7 +25,7 @@ struct CfgT; fn ignore_external() { external! { - #[allow(clippy::needless_borrow)] + #[allow(clippy::needless_borrow)] // Should not lint fn a() {} } }