Skip to main content

display

Function display 

Source
pub fn display(bytes: &[u8]) -> HexDisplay<'_>
Expand description

Get a HexDisplay which provides a Debug and Display impl for the given byte slice. Useful for displaying a hex value without allocating.

Example:

use lexe_hex::hex;
let bytes = [69u8; 32];
println!("Bytes as hex: {}", hex::display(&bytes));