Auto merge of #7099 - ABouttefeux:master, r=llogiq
add type in help message of from_over_into fixes #7088 changelog: add type in help message of from_over_into
This commit is contained in:
commit
e441b33ba0
@ -73,7 +73,7 @@ impl LateLintPass<'_> for FromOverInto {
|
||||
cx.tcx.sess.source_map().guess_head_span(item.span),
|
||||
"an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true",
|
||||
None,
|
||||
"consider to implement `From` instead",
|
||||
&format!("consider to implement `From<{}>` instead", impl_trait_ref.self_ty()),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -5,7 +5,7 @@ LL | impl Into<StringWrapper> for String {
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
|
||||
= note: `-D clippy::from-over-into` implied by `-D warnings`
|
||||
= help: consider to implement `From` instead
|
||||
= help: consider to implement `From<std::string::String>` instead
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user