mirror of
https://github.com/tailscale/tailscale.git
synced 2025-08-11 21:27:31 +00:00
util/deephash: fix unexported time.Time hashing
Updates tailscale/corp#6311 Change-Id: I33cd7e4040966261c2f2eb3d32f29936aeb7f632 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:

committed by
Brad Fitzpatrick

parent
51c3d74095
commit
04cf46a762
16
util/deephash/testtype/testtype.go
Normal file
16
util/deephash/testtype/testtype.go
Normal file
@@ -0,0 +1,16 @@
|
||||
// Copyright (c) 2022 Tailscale Inc & AUTHORS All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
// Package testtype contains types for testing deephash.
|
||||
package testtype
|
||||
|
||||
import "time"
|
||||
|
||||
type UnexportedAddressableTime struct {
|
||||
t time.Time
|
||||
}
|
||||
|
||||
func NewUnexportedAddressableTime(t time.Time) *UnexportedAddressableTime {
|
||||
return &UnexportedAddressableTime{t: t}
|
||||
}
|
Reference in New Issue
Block a user