pub fn decode(data: impl AsRef<[u8]>) -> Result<Vec<u8>, DecodeError>
Decodes a hexadecimal string into bytes.
Returns an error if the input length is odd or contains non-hex characters.