MCPcopy Index your code
hub / github.com/sourcegraph/conc / deref

Method deref

pool/pool.go:127–132  ·  view source on GitHub ↗

deref is a helper that creates a shallow copy of the pool with the same settings. We don't want to just dereference the pointer because that makes the copylock lint angry.

()

Source from the content-addressed store, hash-verified

125// settings. We don't want to just dereference the pointer because that makes
126// the copylock lint angry.
127func (p *Pool) deref() Pool {
128 p.panicIfInitialized()
129 return Pool{
130 limiter: p.limiter,
131 }
132}
133
134// WithContext converts the pool to a ContextPool for tasks that should
135// run under the same context, such that they each respect shared cancellation.

Callers 2

WithErrorsMethod · 0.95
WithContextMethod · 0.45

Calls 1

panicIfInitializedMethod · 0.95

Tested by

no test coverage detected