Skip to content

Commit 23045eb

Browse files
committedNov 27, 2021
Stabilize nonzero_is_power_of_two
Fixes 81106 FCP has finished in the tracking issue
1 parent bbad745 commit 23045eb

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed
 

‎library/core/src/num/nonzero.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -915,15 +915,13 @@ macro_rules! nonzero_unsigned_is_power_of_two {
915915
/// Basic usage:
916916
///
917917
/// ```
918-
/// #![feature(nonzero_is_power_of_two)]
919-
///
920918
#[doc = concat!("let eight = std::num::", stringify!($Ty), "::new(8).unwrap();")]
921919
/// assert!(eight.is_power_of_two());
922920
#[doc = concat!("let ten = std::num::", stringify!($Ty), "::new(10).unwrap();")]
923921
/// assert!(!ten.is_power_of_two());
924922
/// ```
925923
#[must_use]
926-
#[unstable(feature = "nonzero_is_power_of_two", issue = "81106")]
924+
#[stable(feature = "nonzero_is_power_of_two", since = "1.59.0")]
927925
#[inline]
928926
pub const fn is_power_of_two(self) -> bool {
929927
// LLVM 11 normalizes `unchecked_sub(x, 1) & x == 0` to the implementation seen here.

0 commit comments

Comments
 (0)
Please sign in to comment.