From 631cd5845e8de329d0e227aaa707d7ea228b8f8f Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:20:29 +0200 Subject: Merging upstream version 1.70.0+dfsg1. Signed-off-by: Daniel Baumann --- tests/mir-opt/building/uniform_array_move_out.rs | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'tests/mir-opt/building/uniform_array_move_out.rs') diff --git a/tests/mir-opt/building/uniform_array_move_out.rs b/tests/mir-opt/building/uniform_array_move_out.rs index e925036ec..4ba107c87 100644 --- a/tests/mir-opt/building/uniform_array_move_out.rs +++ b/tests/mir-opt/building/uniform_array_move_out.rs @@ -1,14 +1,24 @@ -#![feature(box_syntax)] +#![feature(stmt_expr_attributes, rustc_attrs)] // EMIT_MIR uniform_array_move_out.move_out_from_end.built.after.mir fn move_out_from_end() { - let a = [box 1, box 2]; + let a = [ + #[rustc_box] + Box::new(1), + #[rustc_box] + Box::new(2), + ]; let [.., _y] = a; } // EMIT_MIR uniform_array_move_out.move_out_by_subslice.built.after.mir fn move_out_by_subslice() { - let a = [box 1, box 2]; + let a = [ + #[rustc_box] + Box::new(1), + #[rustc_box] + Box::new(2), + ]; let [_y @ ..] = a; } -- cgit v1.2.3