Function bytes_to_hex
Source pub fn bytes_to_hex<B>(bytes: B) -> String
Expand description
This function uses HEX_STRS
, which (at the time) was faster than format!("{:02x}", ...)
.
§Examples
assert_eq!(zeros::bytes_to_hex( &[202, 254]), "cafe");
assert_eq!(zeros::bytes_to_hex(&[192, 255, 238]), "c0ffee");