Remove two unnecessary clone()
calls.
This commit is contained in:
parent
2b8116dced
commit
36b37e22de
@ -529,11 +529,11 @@ fn check_supplied_sig_against_expectation(
|
||||
); // recreated from (*) above
|
||||
|
||||
// Check that E' = S'.
|
||||
let cause = &self.misc(hir_ty.span);
|
||||
let cause = self.misc(hir_ty.span);
|
||||
let InferOk {
|
||||
value: (),
|
||||
obligations,
|
||||
} = self.at(cause, self.param_env)
|
||||
} = self.at(&cause, self.param_env)
|
||||
.eq(*expected_ty, supplied_ty)?;
|
||||
all_obligations.extend(obligations);
|
||||
|
||||
@ -549,7 +549,7 @@ fn check_supplied_sig_against_expectation(
|
||||
);
|
||||
all_obligations.push(
|
||||
Obligation::new(
|
||||
cause.clone(),
|
||||
cause,
|
||||
self.param_env,
|
||||
ty::Predicate::TypeOutlives(
|
||||
ty::Binder::dummy(
|
||||
|
@ -308,7 +308,7 @@ fn compare_predicate_entailment<'tcx>(
|
||||
|
||||
let cause = ObligationCause {
|
||||
span: impl_err_span,
|
||||
..cause.clone()
|
||||
..cause
|
||||
};
|
||||
|
||||
let mut diag = struct_span_err!(tcx.sess,
|
||||
|
Loading…
Reference in New Issue
Block a user