From 3f04c85e249dbefddc6f45e35146b119b2274ac0 Mon Sep 17 00:00:00 2001 From: Nixon Enraght-Moony Date: Wed, 2 Mar 2022 09:14:53 +0000 Subject: [PATCH] Mark `uint::wrapping_next_power_of_two` as `#[inline]` This brings it in line with `next_power_of_two` and `checked_next_power_of_two` --- library/core/src/num/uint_macros.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/library/core/src/num/uint_macros.rs b/library/core/src/num/uint_macros.rs index feec448ebbdb3..cbcf1617ac506 100644 --- a/library/core/src/num/uint_macros.rs +++ b/library/core/src/num/uint_macros.rs @@ -2225,6 +2225,7 @@ macro_rules! uint_impl { #[doc = concat!("assert_eq!(3", stringify!($SelfT), ".wrapping_next_power_of_two(), 4);")] #[doc = concat!("assert_eq!(", stringify!($SelfT), "::MAX.wrapping_next_power_of_two(), 0);")] /// ``` + #[inline] #[unstable(feature = "wrapping_next_power_of_two", issue = "32463", reason = "needs decision on wrapping behaviour")] #[rustc_const_unstable(feature = "wrapping_next_power_of_two", issue = "32463")]