Auto merge of #5926 - giraffate:improve_lint_message_in_to_string_in_display, r=yaahc

Improve lint message in `to_string_in_display`

This is a follow-up of https://github.com/rust-lang/rust-clippy/pull/5831.

changelog: none
This commit is contained in:
bors 2020-08-22 04:51:38 +00:00
commit b57ef14290
3 changed files with 4 additions and 4 deletions

View file

@ -39,7 +39,7 @@ declare_clippy_lint! {
/// ```
pub TO_STRING_IN_DISPLAY,
correctness,
"to_string method used while implementing Display trait"
"`to_string` method used while implementing `Display` trait"
}
#[derive(Default)]
@ -80,7 +80,7 @@ impl LateLintPass<'_> for ToStringInDisplay {
cx,
TO_STRING_IN_DISPLAY,
expr.span,
"Using to_string in fmt::Display implementation might lead to infinite recursion",
"using `to_string` in `fmt::Display` implementation might lead to infinite recursion",
);
}
}