about summary refs log tree commit diff
path: root/src/libcore
diff options
context:
space:
mode:
authorEduard Burtescu <edy.burt@gmail.com>2016-03-10 21:20:09 +0200
committerEduard Burtescu <edy.burt@gmail.com>2016-03-17 22:48:07 +0200
commit473f804491772fe9a31f4096c3ec8da121fc8294 (patch)
treec487b55e6a1e18350639e5fc52485fb828bacc44 /src/libcore
parent080bd97781ee419722df8394a0155b5db069a490 (diff)
Add #[rustc_no_mir] to make tests pass with -Z orbit.
Diffstat (limited to 'src/libcore')
-rw-r--r--src/libcore/lib.rs1
-rw-r--r--src/libcore/num/mod.rs3
2 files changed, 4 insertions, 0 deletions
diff --git a/src/libcore/lib.rs b/src/libcore/lib.rs
index f76b8655ad1..13d3f42ba18 100644
--- a/src/libcore/lib.rs
+++ b/src/libcore/lib.rs
@@ -72,6 +72,7 @@
 #![feature(reflect)]
 #![feature(unwind_attributes)]
 #![feature(repr_simd, platform_intrinsics)]
+#![feature(rustc_attrs)]
 #![feature(staged_api)]
 #![feature(unboxed_closures)]
 
diff --git a/src/libcore/num/mod.rs b/src/libcore/num/mod.rs
index 5a2a043d6f1..e6f83498ab1 100644
--- a/src/libcore/num/mod.rs
+++ b/src/libcore/num/mod.rs
@@ -1008,6 +1008,7 @@ macro_rules! int_impl {
         /// ```
         #[stable(feature = "rust1", since = "1.0.0")]
         #[inline]
+        #[cfg_attr(not(stage0), rustc_no_mir)] // FIXME #29769 MIR overflow checking is TBD.
         pub fn pow(self, mut exp: u32) -> Self {
             let mut base = self;
             let mut acc = Self::one();
@@ -1049,6 +1050,7 @@ macro_rules! int_impl {
         /// ```
         #[stable(feature = "rust1", since = "1.0.0")]
         #[inline]
+        #[cfg_attr(not(stage0), rustc_no_mir)] // FIXME #29769 MIR overflow checking is TBD.
         pub fn abs(self) -> Self {
             if self.is_negative() {
                 // Note that the #[inline] above means that the overflow
@@ -2013,6 +2015,7 @@ macro_rules! uint_impl {
         /// ```
         #[stable(feature = "rust1", since = "1.0.0")]
         #[inline]
+        #[cfg_attr(not(stage0), rustc_no_mir)] // FIXME #29769 MIR overflow checking is TBD.
         pub fn pow(self, mut exp: u32) -> Self {
             let mut base = self;
             let mut acc = Self::one();