]> git.lizzy.rs Git - rust.git/blobdiff - src/test/codegen/adjustments.rs
Add #[rustc_no_mir] to make tests pass with -Z orbit.
[rust.git] / src / test / codegen / adjustments.rs
index a61fa84398e9aacbd9b8f1958ec2dc71875368c7..20d049394345256dad72cc965d5d1c670b1f0f12 100644 (file)
@@ -11,6 +11,7 @@
 // compile-flags: -C no-prepopulate-passes
 
 #![crate_type = "lib"]
+#![feature(rustc_attrs)]
 
 // Hack to get the correct size for the length part in slices
 // CHECK: @helper([[USIZE:i[0-9]+]])
@@ -20,6 +21,7 @@ fn helper(_: usize) {
 
 // CHECK-LABEL: @no_op_slice_adjustment
 #[no_mangle]
+#[rustc_no_mir] // FIXME #27840 MIR has different codegen.
 pub fn no_op_slice_adjustment(x: &[u8]) -> &[u8] {
     // We used to generate an extra alloca and memcpy for the block's trailing expression value, so
     // check that we copy directly to the return value slot