Tracking Issue for uint_bit_width (original) (raw)
Feature gate: #![feature(uint_bit_width)]
This is a tracking issue for the bit_width method that return the minimum number of bits required to represent an unsigned integer.
This method is implemented for the primitive unsigned integer types and unsigned NonZero<T>.
Public API
impl {u8,u16,u32,u64,u128,usize} { pub const fn bit_width(self) -> u32; }
// For all unsigned T.
impl NonZero {
pub const fn bit_width(self) -> NonZero;
}
Steps / History
(Remember to update the S-tracking-* label when checking boxes.)
- ACP: ACP: Add {u8,u16,u32,u64,u128,usize}::bit_len libs-team#598
- Implementation:
- Final comment period (FCP)1
- Stabilization PR
Unresolved Questions
- None yet.