code: func NewHash(algo api.HashAlgo) (hash.Hash, error) {
  	if err := ValidateHashAlgo(algo); err != nil {
  		return nil, err
  	}
  	return supportedAlgos[algo].hash(), nil
  }
docs: // NewHash returns a hash implementation or an error if the algo is unknown.