compute

Function compute 

Source
pub fn compute(bits_width: usize, hash: impl Fn(&[u8], u64, &mut [u8])) -> u32
Expand description

Computes hash verification code that used in SMHasher.

  • bits_width: Output width in bits. Must be no less than 32.
  • hash: Function hash(bytes: &[u8], seed: u64, out: &mut [u8]).

ยงPanics

If bits_width is less than 32 or not a multiple of 8.