Update clippy_lints/src/methods/mod.rs

Co-authored-by: Eduardo Broto <ebroto@tutanota.com>
This commit is contained in:
Thibaud 2020-08-25 22:20:35 +02:00 committed by GitHub
parent 3d820f71fe
commit 370fc45a0a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2150,11 +2150,7 @@ fn lint_clone_on_ref_ptr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, arg: &hir::
return;
};
let snippet = if in_macro(arg.span) {
snippet_with_macro_callsite(cx, arg.span, "_")
} else {
snippet(cx, arg.span, "_")
};
let snippet = snippet_with_macro_callsite(cx, arg.span, "_");
span_lint_and_sugg(
cx,