diff options
| author | Philipp Krones <hello@philkrones.com> | 2022-09-28 14:27:32 +0200 |
|---|---|---|
| committer | Philipp Krones <hello@philkrones.com> | 2022-09-28 14:27:32 +0200 |
| commit | bbcde666853d11f6f5f3bdc660f018cf7fc8cd71 (patch) | |
| tree | 28df6eeea41c8e772bb65a172962f74282db1de1 /clippy_lints/src/methods/map_clone.rs | |
| parent | e5ce6d18df883f593e72f7958bebdc3ebcdbe85e (diff) | |
| parent | 0f6932a1f7623663e50922225ea304340949c051 (diff) | |
| download | rust-bbcde666853d11f6f5f3bdc660f018cf7fc8cd71.tar.gz rust-bbcde666853d11f6f5f3bdc660f018cf7fc8cd71.zip | |
Merge remote-tracking branch 'upstream/master' into rustup
Diffstat (limited to 'clippy_lints/src/methods/map_clone.rs')
| -rw-r--r-- | clippy_lints/src/methods/map_clone.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/clippy_lints/src/methods/map_clone.rs b/clippy_lints/src/methods/map_clone.rs index 8261ef5e1ce..7ce14ec080b 100644 --- a/clippy_lints/src/methods/map_clone.rs +++ b/clippy_lints/src/methods/map_clone.rs @@ -111,11 +111,10 @@ fn lint_explicit_closure(cx: &LateContext<'_>, replace: Span, root: Span, is_cop MAP_CLONE, replace, message, - &format!("consider calling the dedicated `{}` method", sugg_method), + &format!("consider calling the dedicated `{sugg_method}` method"), format!( - "{}.{}()", + "{}.{sugg_method}()", snippet_with_applicability(cx, root, "..", &mut applicability), - sugg_method, ), applicability, ); |
