Rollup merge of #77037 - matthiaskrgr:cl42ppy, r=Dylan-DPC
more tiny clippy cleanups commits stand alone and can be reviewed one by one
This commit is contained in:
commit
248d6bf1e2
3 changed files with 4 additions and 7 deletions
|
@ -62,8 +62,7 @@ impl<'a, 'tcx> ConstraintConversion<'a, 'tcx> {
|
|||
// `self.constraints`, but we also want to be mutating
|
||||
// `self.member_constraints`. For now, just swap out the value
|
||||
// we want and replace at the end.
|
||||
let mut tmp =
|
||||
std::mem::replace(&mut self.constraints.member_constraints, Default::default());
|
||||
let mut tmp = std::mem::take(&mut self.constraints.member_constraints);
|
||||
for member_constraint in member_constraints {
|
||||
tmp.push_constraint(member_constraint, |r| self.to_region_vid(r));
|
||||
}
|
||||
|
|
|
@ -91,7 +91,7 @@ impl<'tcx> MirPass<'tcx> for EarlyOtherwiseBranch {
|
|||
let not_equal_rvalue = Rvalue::BinaryOp(
|
||||
not_equal,
|
||||
Operand::Copy(Place::from(second_discriminant_temp)),
|
||||
Operand::Copy(Place::from(first_descriminant_place)),
|
||||
Operand::Copy(first_descriminant_place),
|
||||
);
|
||||
patch.add_statement(
|
||||
end_of_block_location,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue