summaryrefslogtreecommitdiffstats
path: root/tests/mir-opt/const_prop/boxes.rs
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:20:39 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:20:39 +0000
commit1376c5a617be5c25655d0d7cb63e3beaa5a6e026 (patch)
tree3bb8d61aee02bc7a15eab3f36e3b921afc2075d0 /tests/mir-opt/const_prop/boxes.rs
parentReleasing progress-linux version 1.69.0+dfsg1-1~progress7.99u1. (diff)
downloadrustc-1376c5a617be5c25655d0d7cb63e3beaa5a6e026.tar.xz
rustc-1376c5a617be5c25655d0d7cb63e3beaa5a6e026.zip
Merging upstream version 1.70.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/mir-opt/const_prop/boxes.rs')
-rw-r--r--tests/mir-opt/const_prop/boxes.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/mir-opt/const_prop/boxes.rs b/tests/mir-opt/const_prop/boxes.rs
index d287830db..66e8c24d4 100644
--- a/tests/mir-opt/const_prop/boxes.rs
+++ b/tests/mir-opt/const_prop/boxes.rs
@@ -4,11 +4,13 @@
// ignore-wasm32
// ignore-wasm64
-#![feature(box_syntax)]
+#![feature(rustc_attrs, stmt_expr_attributes)]
-// Note: this test verifies that we, in fact, do not const prop `box`
+// Note: this test verifies that we, in fact, do not const prop `#[rustc_box]`
// EMIT_MIR boxes.main.ConstProp.diff
fn main() {
- let x = *(box 42) + 0;
+ let x = *(#[rustc_box]
+ Box::new(42))
+ + 0;
}