fn decode_hex_public_key(public_key_hex: &str) -> Result<PublicKey, String> {
    let public_key_bytes =
        hex::decode(public_key_hex).map_err(|_| "Could not hex-decode public key".to_string())?;

    let format = Some(PublicKeyFormat::Full);

    PublicKey::parse_slice(&public_key_bytes, format)
        .map_err(|_| "Could not parse hex-decoded public key".to_string())
}
/// Attempt to convert a hex string into a `PublicKey`
Attempt to convert a hex string into a `PublicKey`
Attempt to convert a hex string into a ` PublicKey `
fn decode_hex_public_key(public_key_hex: &str) -> Result<PublicKey, String> {
    let public_key_bytes =
        hex::decode(public_key_hex).map_err(|_| "Could not hex-decode public key".to_string())?;
    let format = Some(PublicKeyFormat::Full);
    PublicKey::parse_slice(&public_key_bytes, format)
        .map_err(|_| "Could not parse hex-decoded public key".to_string())
}
fn decode_hex_public_key ( public_key_hex : & str ) -> Result < PublicKey , String > { let public_key_bytes = hex :: decode ( public_key_hex ) . map_err ( | _ | " " . to_string ( ) ) ? ; let format = Some ( PublicKeyFormat :: Full ) ; PublicKey :: parse_slice ( & public_key_bytes , format ) . map_err ( | _ | " " . to_string ( ) ) }
Attempt to convert a hex string into a `PublicKey`
Attempt to convert a hex string into a ` PublicKey `
public_key_hex
&str
public_key_hex
&str