From 0cc1c8d2e71f798ca28813e5dca3adb0e791684d Mon Sep 17 00:00:00 2001 From: Dante-Broggi <34220985+Dante-Broggi@users.noreply.github.com> Date: Thu, 29 Aug 2019 14:16:52 -0400 Subject: [PATCH] `new_thin_place` is only used with `align` = `layout.align.abi` and is not `pub`. --- src/librustc_codegen_ssa/mir/place.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/librustc_codegen_ssa/mir/place.rs b/src/librustc_codegen_ssa/mir/place.rs index ac72928a8967..bd295565e67b 100644 --- a/src/librustc_codegen_ssa/mir/place.rs +++ b/src/librustc_codegen_ssa/mir/place.rs @@ -45,14 +45,13 @@ impl<'a, 'tcx, V: CodegenObject> PlaceRef<'tcx, V> { bx: &mut Bx, llval: V, layout: TyLayout<'tcx>, - align: Align, ) -> PlaceRef<'tcx, V> { assert!(!bx.cx().type_has_metadata(layout.ty)); PlaceRef { llval, llextra: None, layout, - align + align: layout.align.abi } } @@ -498,7 +497,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> { // with a static that is an extern_type. let layout = cx.layout_of(self.monomorphize(&ty)); let static_ = bx.get_static(*def_id); - PlaceRef::new_thin_place(bx, static_, layout, layout.align.abi) + PlaceRef::new_thin_place(bx, static_, layout) }, mir::PlaceRef { base,