@@ -2025,17 +2025,17 @@ macro_rules! int_impl {
20252025 #[ doc = concat!( "let a: " , stringify!( $SelfT) , " = 8;" ) ]
20262026 /// let b = 3;
20272027 ///
2028- /// assert_eq!(a.unstable_div_floor (b), 2);
2029- /// assert_eq!(a.unstable_div_floor (-b), -3);
2030- /// assert_eq!((-a).unstable_div_floor (b), -3);
2031- /// assert_eq!((-a).unstable_div_floor (-b), 2);
2028+ /// assert_eq!(a.div_floor (b), 2);
2029+ /// assert_eq!(a.div_floor (-b), -3);
2030+ /// assert_eq!((-a).div_floor (b), -3);
2031+ /// assert_eq!((-a).div_floor (-b), 2);
20322032 /// ```
20332033 #[ unstable( feature = "int_roundings" , issue = "88581" ) ]
20342034 #[ must_use = "this returns the result of the operation, \
20352035 without modifying the original"]
20362036 #[ inline]
20372037 #[ rustc_inherit_overflow_checks]
2038- pub const fn unstable_div_floor ( self , rhs: Self ) -> Self {
2038+ pub const fn div_floor ( self , rhs: Self ) -> Self {
20392039 let d = self / rhs;
20402040 let r = self % rhs;
20412041 if ( r > 0 && rhs < 0 ) || ( r < 0 && rhs > 0 ) {
@@ -2060,17 +2060,17 @@ macro_rules! int_impl {
20602060 #[ doc = concat!( "let a: " , stringify!( $SelfT) , " = 8;" ) ]
20612061 /// let b = 3;
20622062 ///
2063- /// assert_eq!(a.unstable_div_ceil (b), 3);
2064- /// assert_eq!(a.unstable_div_ceil (-b), -2);
2065- /// assert_eq!((-a).unstable_div_ceil (b), -2);
2066- /// assert_eq!((-a).unstable_div_ceil (-b), 3);
2063+ /// assert_eq!(a.div_ceil (b), 3);
2064+ /// assert_eq!(a.div_ceil (-b), -2);
2065+ /// assert_eq!((-a).div_ceil (b), -2);
2066+ /// assert_eq!((-a).div_ceil (-b), 3);
20672067 /// ```
20682068 #[ unstable( feature = "int_roundings" , issue = "88581" ) ]
20692069 #[ must_use = "this returns the result of the operation, \
20702070 without modifying the original"]
20712071 #[ inline]
20722072 #[ rustc_inherit_overflow_checks]
2073- pub const fn unstable_div_ceil ( self , rhs: Self ) -> Self {
2073+ pub const fn div_ceil ( self , rhs: Self ) -> Self {
20742074 let d = self / rhs;
20752075 let r = self % rhs;
20762076 if ( r > 0 && rhs > 0 ) || ( r < 0 && rhs < 0 ) {
@@ -2095,21 +2095,21 @@ macro_rules! int_impl {
20952095 ///
20962096 /// ```
20972097 /// #![feature(int_roundings)]
2098- #[ doc = concat!( "assert_eq!(16_" , stringify!( $SelfT) , ".unstable_next_multiple_of (8), 16);" ) ]
2099- #[ doc = concat!( "assert_eq!(23_" , stringify!( $SelfT) , ".unstable_next_multiple_of (8), 24);" ) ]
2100- #[ doc = concat!( "assert_eq!(16_" , stringify!( $SelfT) , ".unstable_next_multiple_of (-8), 16);" ) ]
2101- #[ doc = concat!( "assert_eq!(23_" , stringify!( $SelfT) , ".unstable_next_multiple_of (-8), 16);" ) ]
2102- #[ doc = concat!( "assert_eq!((-16_" , stringify!( $SelfT) , ").unstable_next_multiple_of (8), -16);" ) ]
2103- #[ doc = concat!( "assert_eq!((-23_" , stringify!( $SelfT) , ").unstable_next_multiple_of (8), -16);" ) ]
2104- #[ doc = concat!( "assert_eq!((-16_" , stringify!( $SelfT) , ").unstable_next_multiple_of (-8), -16);" ) ]
2105- #[ doc = concat!( "assert_eq!((-23_" , stringify!( $SelfT) , ").unstable_next_multiple_of (-8), -24);" ) ]
2098+ #[ doc = concat!( "assert_eq!(16_" , stringify!( $SelfT) , ".next_multiple_of (8), 16);" ) ]
2099+ #[ doc = concat!( "assert_eq!(23_" , stringify!( $SelfT) , ".next_multiple_of (8), 24);" ) ]
2100+ #[ doc = concat!( "assert_eq!(16_" , stringify!( $SelfT) , ".next_multiple_of (-8), 16);" ) ]
2101+ #[ doc = concat!( "assert_eq!(23_" , stringify!( $SelfT) , ".next_multiple_of (-8), 16);" ) ]
2102+ #[ doc = concat!( "assert_eq!((-16_" , stringify!( $SelfT) , ").next_multiple_of (8), -16);" ) ]
2103+ #[ doc = concat!( "assert_eq!((-23_" , stringify!( $SelfT) , ").next_multiple_of (8), -16);" ) ]
2104+ #[ doc = concat!( "assert_eq!((-16_" , stringify!( $SelfT) , ").next_multiple_of (-8), -16);" ) ]
2105+ #[ doc = concat!( "assert_eq!((-23_" , stringify!( $SelfT) , ").next_multiple_of (-8), -24);" ) ]
21062106 /// ```
21072107 #[ unstable( feature = "int_roundings" , issue = "88581" ) ]
21082108 #[ must_use = "this returns the result of the operation, \
21092109 without modifying the original"]
21102110 #[ inline]
21112111 #[ rustc_inherit_overflow_checks]
2112- pub const fn unstable_next_multiple_of ( self , rhs: Self ) -> Self {
2112+ pub const fn next_multiple_of ( self , rhs: Self ) -> Self {
21132113 // This would otherwise fail when calculating `r` when self == T::MIN.
21142114 if rhs == -1 {
21152115 return self ;
0 commit comments