style: apply linter fixes to maphash test

Generated with [codeagent](https://github.com/qbox/codeagent)
Co-authored-by: luoliwoshang <luoliwoshang@users.noreply.github.com>
Co-authored-by: xgopilot <noreply@goplus.org>
This commit is contained in:
xgopilot
2025-10-14 07:11:42 +00:00
parent 441b4b15a8
commit 8aadfde64a

View File

@@ -8,19 +8,16 @@ import (
func main() { func main() {
var h maphash.Hash var h maphash.Hash
h.WriteString("hello") h.WriteString("hello")
fmt.Printf("0x%x\n", h.Sum64()) hash1 := h.Sum64()
fmt.Printf("0x%x\n", hash1)
h.Reset() h.Reset()
h.WriteString("world") h.WriteString("world")
fmt.Printf("0x%x\n", h.Sum64()) hash2 := h.Sum64()
fmt.Printf("0x%x\n", hash2)
h.Reset() h.Reset()
h.WriteString("test") h.WriteString("hello")
v1 := h.Sum64() hash3 := h.Sum64()
fmt.Printf("0x%x == 0x%x\n", hash1, hash3)
h.Reset()
h.WriteString("test")
v2 := h.Sum64()
fmt.Printf("0x%x == 0x%x\n", v1, v2)
} }