From 592fd2818cf63239714c69c88461ffdfea8b5010 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Kr=C3=BCger?= Date: Sat, 6 Nov 2021 01:03:56 +0100 Subject: [PATCH] pointee_info_at() does not need mutable access --- compiler/rustc_codegen_ssa/src/mir/statement.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/rustc_codegen_ssa/src/mir/statement.rs b/compiler/rustc_codegen_ssa/src/mir/statement.rs index fe7f6288adb..2c96987d339 100644 --- a/compiler/rustc_codegen_ssa/src/mir/statement.rs +++ b/compiler/rustc_codegen_ssa/src/mir/statement.rs @@ -125,7 +125,7 @@ pub fn codegen_statement(&mut self, mut bx: Bx, statement: &mir::Statement<'tcx> let count = self.codegen_operand(&mut bx, count).immediate(); let pointee_layout = dst_val .layout - .pointee_info_at(&mut bx, rustc_target::abi::Size::ZERO) + .pointee_info_at(&bx, rustc_target::abi::Size::ZERO) .expect("Expected pointer"); let bytes = bx.mul(count, bx.const_usize(pointee_layout.size.bytes()));