fix(unnecessary_map_or): respect reduced applicability
This commit is contained in:
parent
1437ea04e8
commit
2e556c490b
1 changed files with 2 additions and 2 deletions
|
|
@ -97,12 +97,12 @@ pub(super) fn check<'a>(
|
|||
// being converted to `Some(5) == Some(5).then(|| 1)` isn't
|
||||
// the same thing
|
||||
|
||||
let mut app = Applicability::MachineApplicable;
|
||||
let inner_non_binding = Sugg::NonParen(Cow::Owned(format!(
|
||||
"{wrap}({})",
|
||||
Sugg::hir(cx, non_binding_location, "")
|
||||
Sugg::hir_with_applicability(cx, non_binding_location, "", &mut app)
|
||||
)));
|
||||
|
||||
let mut app = Applicability::MachineApplicable;
|
||||
let binop = make_binop(
|
||||
op.node,
|
||||
&Sugg::hir_with_applicability(cx, recv, "..", &mut app),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue