2 use crate::fmt::{Debug, Formatter, Result};
6 struct Helper<'a>(&'a [u8]);
8 impl Debug for Helper<'_> {
9 fn fmt(&self, f: &mut Formatter<'_>) -> Result {
10 debug_fmt_bytestring(self.0, f)
14 let input = b"\xF0hello,\tworld";
15 let expected = r#""\xF0hello,\tworld""#;
16 let output = format!("{:?}", Helper(input));
18 assert!(output == expected);