code: func registerHashAlgo(algo api.HashAlgo, h func() hash.Hash) {
  	if supportedAlgos[algo].hash != nil {
  		panic(fmt.Sprintf("hash algo %s is already registered", algo))
  	}
  	inst := h()
  	supportedAlgos[algo].hash = h
  	supportedAlgos[algo].typ = reflect.TypeOf(inst)
  	supportedAlgos[algo].hexDigestLen = 2 * len(inst.Sum(nil))
  }
docs: // registerHash is used from hash_*.go files to update supportedAlgos.