Skip to content

Commit e546452

Browse files
committed
auto merge of #14305 : tbu-/rust/pr_doc_bytes, r=huonw
Only an example was needed, as the ability to write uints into the string is already mentioned. Fix #7102.
2 parents 6ecf7d9 + 84f43c6 commit e546452

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/libstd/macros.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -471,8 +471,9 @@ pub mod builtin {
471471
/// # Example
472472
///
473473
/// ```
474-
/// let rust = bytes!("r", 'u', "st");
474+
/// let rust = bytes!("r", 'u', "st", 255);
475475
/// assert_eq!(rust[1], 'u' as u8);
476+
/// assert_eq!(rust[5], 255);
476477
/// ```
477478
#[macro_export]
478479
macro_rules! bytes( ($($e:expr),*) => ({ /* compiler built-in */ }) )

0 commit comments

Comments
 (0)