tailscale/util/deephash
Joe Tsai 9a0c8bdd20 util/deephash: make hash type opaque
The fact that Hash returns a [sha256.Size]byte leaks details about
the underlying hash implementation. This could very well be any other
hashing algorithm with a possible different block size.

Abstract this implementation detail away by declaring an opaque type
that is comparable. While we are changing the signature of UpdateHash,
rename it to just Update to reduce stutter (e.g., deephash.Update).

Signed-off-by: Joe Tsai <joetsai@digital-static.net>
2021-07-20 11:03:25 -07:00
..
deephash_test.go util/deephash: make hash type opaque 2021-07-20 11:03:25 -07:00
deephash.go util/deephash: make hash type opaque 2021-07-20 11:03:25 -07:00
fmtsort.go util/deephash: move internal/deephash to util/deephash 2021-07-02 21:33:02 -07:00
mapiter_future.go util/deephash: move internal/deephash to util/deephash 2021-07-02 21:33:02 -07:00
mapiter.go util/deephash: move internal/deephash to util/deephash 2021-07-02 21:33:02 -07:00