librustc{, codegen_ssa,infer,mir_build}: don't clone types that are copy
This commit is contained in:
parent
5ae4500eff
commit
d4a005bd03
6 changed files with 6 additions and 6 deletions
|
|
@ -31,7 +31,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
|
|||
_ => {
|
||||
let val = self.eval_mir_constant(constant)?;
|
||||
let ty = self.monomorphize(&constant.literal.ty);
|
||||
Ok(OperandRef::from_const(bx, val.clone(), ty))
|
||||
Ok(OperandRef::from_const(bx, val, ty))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue