about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSantiago Pastorino <spastorino@gmail.com>2020-03-31 14:35:01 -0300
committerSantiago Pastorino <spastorino@gmail.com>2020-03-31 17:37:54 -0300
commit1f5338cfd61b3eb59c2491fffdd802ce779c6487 (patch)
tree91a294f1afbb9609efe0f93aaf7075cb82f32c73
parent5f8a6edbbbfd0289a74d1689fbeb9387350eb4f3 (diff)
downloadrust-1f5338cfd61b3eb59c2491fffdd802ce779c6487.tar.gz
rust-1f5338cfd61b3eb59c2491fffdd802ce779c6487.zip
Use Place directly in codegen_transmute, it's Copy
-rw-r--r--src/librustc_codegen_ssa/mir/block.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librustc_codegen_ssa/mir/block.rs b/src/librustc_codegen_ssa/mir/block.rs
index d75818dfbac..931fab6ae01 100644
--- a/src/librustc_codegen_ssa/mir/block.rs
+++ b/src/librustc_codegen_ssa/mir/block.rs
@@ -580,7 +580,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
 
         if intrinsic == Some("transmute") {
             if let Some(destination_ref) = destination.as_ref() {
-                let &(ref dest, target) = destination_ref;
+                let &(dest, target) = destination_ref;
                 self.codegen_transmute(&mut bx, &args[0], dest);
                 helper.maybe_sideeffect(self.mir, &mut bx, &[target]);
                 helper.funclet_br(self, &mut bx, target);
@@ -1184,7 +1184,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
         }
     }
 
-    fn codegen_transmute(&mut self, bx: &mut Bx, src: &mir::Operand<'tcx>, dst: &mir::Place<'tcx>) {
+    fn codegen_transmute(&mut self, bx: &mut Bx, src: &mir::Operand<'tcx>, dst: mir::Place<'tcx>) {
         if let Some(index) = dst.as_local() {
             match self.locals[index] {
                 LocalRef::Place(place) => self.codegen_transmute_into(bx, src, place),