]> git.lizzy.rs Git - rust.git/blobdiff - src/test/run-fail/overflowing-rsh-3.rs
Add #[rustc_no_mir] to make tests pass with -Z orbit.
[rust.git] / src / test / run-fail / overflowing-rsh-3.rs
index c261e195fd71ebe3b39d72f35418aa05446639fc..8874587064c35ec26f45bf7cc1e4ebdc09f565ba 100644 (file)
@@ -8,12 +8,15 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// ignore-pretty : (#23623) problems when  ending with // comments
+
 // error-pattern:thread '<main>' panicked at 'shift operation overflowed'
 // compile-flags: -C debug-assertions
 
-// (Work around constant-evaluation)
-fn id<T>(x: T) -> T { x }
+#![warn(exceeding_bitshifts)]
 
+#![feature(rustc_attrs)]
+#[rustc_no_mir] // FIXME #29769 MIR overflow checking is TBD.
 fn main() {
-    let _x = -1_i64 >> id(64);
+    let _x = -1_i64 >> 64;
 }