Skip to content

Commit 7ed2d56

Browse files
committed
test: Update doc tests for bit_width
1 parent b3404d2 commit 7ed2d56

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

library/core/src/num/uint_macros.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,8 +224,9 @@ macro_rules! uint_impl {
224224
/// ```
225225
/// #![feature(uint_bit_width)]
226226
///
227-
#[doc = concat!("assert_eq!(0", stringify!($SelfT), ".bit_width(), 0);")]
228-
#[doc = concat!("assert_eq!(7", stringify!($SelfT), ".bit_width(), 3);")]
227+
#[doc = concat!("assert_eq!(0_", stringify!($SelfT), ".bit_width(), 0);")]
228+
#[doc = concat!("assert_eq!(0b111_", stringify!($SelfT), ".bit_width(), 3);")]
229+
#[doc = concat!("assert_eq!(0b1110_", stringify!($SelfT), ".bit_width(), 4);")]
229230
#[doc = concat!("assert_eq!(", stringify!($SelfT), "::MAX.bit_width(), ", stringify!($BITS), ");")]
230231
/// ```
231232
#[unstable(feature = "uint_bit_width", issue = "142326")]

0 commit comments

Comments
 (0)