We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aae5951 commit 40d74fdCopy full SHA for 40d74fd
clippy_lints/src/into_instead_of_from.rs
@@ -37,15 +37,14 @@ impl LateLintPass<'tcx> for IntoInsteadOfFrom {
37
if_chain! {
38
if let Some(tr_ref) = wbp.bounds[0].trait_ref();
39
if let Some(def_id) = tr_ref.trait_def_id();
40
+ if cx.tcx.is_diagnostic_item(sym::from_trait, def_id);
41
then {
- if cx.tcx.is_diagnostic_item(sym::from_trait, def_id) {
42
- span_lint(
43
- cx,
44
- INTO_INSTEAD_OF_FROM,
45
- wp.span(),
46
- "What is WHERE PREDICATE"
47
- );
48
- }
+ span_lint(
+ cx,
+ INTO_INSTEAD_OF_FROM,
+ wp.span(),
+ "What is WHERE PREDICATE"
+ );
49
}
50
51
},
0 commit comments