pub fn parse_hex_string<F: FromStr>(hex_str: &str) -> Result<F, F::Err>