]> git.proxmox.com Git - rustc.git/blobdiff - compiler/rustc_codegen_cranelift/src/base.rs
New upstream version 1.62.1+dfsg1
[rustc.git] / compiler / rustc_codegen_cranelift / src / base.rs
index a9ff710c91ed6f865cb4486e7f96031b0f4e3b56..65346cb39622aa0e7bc2a7de747820af62b3d519 100644 (file)
@@ -772,6 +772,7 @@ fn codegen_stmt<'tcx>(
         }
         StatementKind::StorageLive(_)
         | StatementKind::StorageDead(_)
+        | StatementKind::Deinit(_)
         | StatementKind::Nop
         | StatementKind::FakeRead(..)
         | StatementKind::Retag { .. }
@@ -820,7 +821,8 @@ pub(crate) fn codegen_place<'tcx>(
                 if cplace.layout().ty.is_box() {
                     cplace = cplace
                         .place_field(fx, Field::new(0)) // Box<T> -> Unique<T>
-                        .place_field(fx, Field::new(0)) // Unique<T> -> *const T
+                        .place_field(fx, Field::new(0)) // Unique<T> -> NonNull<T>
+                        .place_field(fx, Field::new(0)) // NonNull<T> -> *mut T
                         .place_deref(fx);
                 } else {
                     cplace = cplace.place_deref(fx);