don't clone Copy types
This commit is contained in:
parent
35a99eef32
commit
fec9e9ecf1
11 changed files with 16 additions and 16 deletions
|
@ -148,7 +148,7 @@ impl<'s, 'tcx, D: ConstraintGraphDirecton> Iterator for Edges<'s, 'tcx, D> {
|
|||
if let Some(p) = self.pointer {
|
||||
self.pointer = self.graph.next_constraints[p];
|
||||
|
||||
Some(self.constraints[p].clone())
|
||||
Some(self.constraints[p])
|
||||
} else if let Some(next_static_idx) = self.next_static_idx {
|
||||
self.next_static_idx = if next_static_idx == (self.graph.first_constraints.len() - 1) {
|
||||
None
|
||||
|
|
|
@ -612,7 +612,7 @@ impl<'a, 'b, 'tcx> TypeVerifier<'a, 'b, 'tcx> {
|
|||
|
||||
let locations = location.to_locations();
|
||||
for constraint in constraints.outlives().iter() {
|
||||
let mut constraint = constraint.clone();
|
||||
let mut constraint = *constraint;
|
||||
constraint.locations = locations;
|
||||
if let ConstraintCategory::Return(_)
|
||||
| ConstraintCategory::UseAsConst
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue