mirror of
https://github.com/golang/go.git
synced 2025-05-05 15:43:04 +00:00
internal/memoize: add a go:nocheckptr annotation to (*Store).get
Fixes golang/go#35125 Change-Id: I08251b94a44fbc2324f6edc883d9d687b45a00b0 Reviewed-on: https://go-review.googlesource.com/c/tools/+/203078 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
This commit is contained in:
parent
2b779830f9
commit
7b6f5d95f3
@ -121,6 +121,8 @@ func (s *Store) Cached(key interface{}) interface{} {
|
||||
return h.Cached()
|
||||
}
|
||||
|
||||
//go:nocheckptr
|
||||
// nocheckptr because: https://github.com/golang/go/issues/35125#issuecomment-545671062
|
||||
func (s *Store) get(key interface{}) *Handle {
|
||||
// this must be called with the store mutex already held
|
||||
e, found := s.entries[key]
|
||||
|
Loading…
x
Reference in New Issue
Block a user