diff --git a/library/core/src/intrinsics.rs b/library/core/src/intrinsics.rs index 0130586b430..653fbcabfe5 100644 --- a/library/core/src/intrinsics.rs +++ b/library/core/src/intrinsics.rs @@ -1593,7 +1593,7 @@ extern "rust-intrinsic" { /// Safe wrappers for this intrinsic are available on the integer /// primitives via the `checked_div` method. For example, /// [`u32::checked_div`] - #[rustc_const_unstable(feature = "const_int_unchecked_arith", issue = "none")] + #[rustc_const_stable(feature = "const_int_unchecked_arith", since = "1.51.0")] pub fn unchecked_div(x: T, y: T) -> T; /// Returns the remainder of an unchecked division, resulting in /// undefined behavior when `y == 0` or `x == T::MIN && y == -1` @@ -1601,7 +1601,7 @@ extern "rust-intrinsic" { /// Safe wrappers for this intrinsic are available on the integer /// primitives via the `checked_rem` method. For example, /// [`u32::checked_rem`] - #[rustc_const_unstable(feature = "const_int_unchecked_arith", issue = "none")] + #[rustc_const_stable(feature = "const_int_unchecked_arith", since = "1.51.0")] pub fn unchecked_rem(x: T, y: T) -> T; /// Performs an unchecked left shift, resulting in undefined behavior when diff --git a/library/core/src/num/int_macros.rs b/library/core/src/num/int_macros.rs index 810ca9b357e..2e2e1b0f2ec 100644 --- a/library/core/src/num/int_macros.rs +++ b/library/core/src/num/int_macros.rs @@ -514,7 +514,6 @@ macro_rules! int_impl { /// ``` #[stable(feature = "rust1", since = "1.0.0")] #[rustc_const_stable(feature = "const_checked_int_methods", since = "1.51.0")] - #[rustc_allow_const_fn_unstable(const_int_unchecked_arith)] #[must_use = "this returns the result of the operation, \ without modifying the original"] #[inline] @@ -567,7 +566,6 @@ macro_rules! int_impl { /// ``` #[stable(feature = "wrapping", since = "1.7.0")] #[rustc_const_stable(feature = "const_checked_int_methods", since = "1.51.0")] - #[rustc_allow_const_fn_unstable(const_int_unchecked_arith)] #[must_use = "this returns the result of the operation, \ without modifying the original"] #[inline] diff --git a/library/core/src/num/uint_macros.rs b/library/core/src/num/uint_macros.rs index 89b16342d95..3f235c20123 100644 --- a/library/core/src/num/uint_macros.rs +++ b/library/core/src/num/uint_macros.rs @@ -523,7 +523,6 @@ macro_rules! uint_impl { /// ``` #[stable(feature = "rust1", since = "1.0.0")] #[rustc_const_stable(feature = "const_checked_int_methods", since = "1.51.0")] - #[rustc_allow_const_fn_unstable(const_int_unchecked_arith)] #[must_use = "this returns the result of the operation, \ without modifying the original"] #[inline] @@ -575,7 +574,6 @@ macro_rules! uint_impl { /// ``` #[stable(feature = "wrapping", since = "1.7.0")] #[rustc_const_stable(feature = "const_checked_int_methods", since = "1.51.0")] - #[rustc_allow_const_fn_unstable(const_int_unchecked_arith)] #[must_use = "this returns the result of the operation, \ without modifying the original"] #[inline]