mirror of
https://github.com/rust-lang/rust-clippy
synced 2025-02-25 20:07:21 +00:00
Fix lint message
This commit is contained in:
parent
6aa06b757d
commit
4166b7dcfe
2 changed files with 2 additions and 2 deletions
|
@ -23,7 +23,7 @@ pub(super) fn check_fn<'tcx>(cx: &LateContext<'_>, kind: &'tcx FnKind<'_>, body:
|
||||||
if let Some(gen_span) = generics.span_for_param_suggestion() {
|
if let Some(gen_span) = generics.span_for_param_suggestion() {
|
||||||
diag.span_suggestion_with_style(
|
diag.span_suggestion_with_style(
|
||||||
gen_span,
|
gen_span,
|
||||||
"add a type paremeter, `{}`: `{}`",
|
"add a type paremeter",
|
||||||
format!(", {next_letter}: {}", ¶m.name.ident().as_str()[5..]),
|
format!(", {next_letter}: {}", ¶m.name.ident().as_str()[5..]),
|
||||||
rustc_errors::Applicability::MaybeIncorrect,
|
rustc_errors::Applicability::MaybeIncorrect,
|
||||||
rustc_errors::SuggestionStyle::ShowAlways,
|
rustc_errors::SuggestionStyle::ShowAlways,
|
||||||
|
|
|
@ -16,7 +16,7 @@ error: '`impl Trait` used as a function parameter'
|
||||||
LL | pub fn c<C: Trait>(_: C, _: impl Trait) {}
|
LL | pub fn c<C: Trait>(_: C, _: impl Trait) {}
|
||||||
| ^^^^^^^^^^
|
| ^^^^^^^^^^
|
||||||
|
|
|
|
||||||
help: add a type paremeter, `{}`: `{}`
|
help: add a type paremeter
|
||||||
|
|
|
|
||||||
LL | pub fn c<C: Trait, T: Trait>(_: C, _: impl Trait) {}
|
LL | pub fn c<C: Trait, T: Trait>(_: C, _: impl Trait) {}
|
||||||
| ++++++++++
|
| ++++++++++
|
||||||
|
|
Loading…
Add table
Reference in a new issue