Macro alloy_primitives::address
source · macro_rules! address { () => { ... }; ($($t:tt)+) => { ... }; }
Expand description
Converts a sequence of string literals containing hex-encoded data
into a new Address
at compile time.
If the input is empty, a zero-initialized array is returned.
See hex!
for more information.
§Examples
use alloy_primitives::{address, Address};
const ZERO: Address = address!();
assert_eq!(ZERO, Address::ZERO);
let byte_array: Address = address!("0x0123abcd…");