Function nix_compat::nixhash::from_algo_and_digest

source ·
pub fn from_algo_and_digest(
    algo: HashAlgo,
    digest: &[u8],
) -> NixHashResult<NixHash>
Expand description

Constructs a new NixHash by specifying HashAlgo and digest. It can fail if the passed digest length doesn’t match what’s expected for the passed algo.