MCPcopy
hub / github.com/dropbox/godropbox / get

Method get

strings/intern.go:34–39  ·  view source on GitHub ↗
(s string)

Source from the content-addressed store, hash-verified

32}
33
34func (p *InternStringPool) get(s string) (string, bool) {
35 p.mutex.RLock()
36 z, ok := p.pool[s]
37 p.mutex.RUnlock()
38 return z, ok
39}
40
41func (p *InternStringPool) intern(s string, shouldCopy bool) string {
42 z, ok := p.get(s)

Callers 1

internMethod · 0.95

Calls 2

RLockMethod · 0.65
RUnlockMethod · 0.65

Tested by

no test coverage detected