We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3eec878 commit a2c7112Copy full SHA for a2c7112
src/sync/pool.go
@@ -8,6 +8,9 @@ type Pool struct {
8
9
// Get returns the value of calling Pool.New().
10
func (p *Pool) Get() interface{} {
11
+ if p.New == nil {
12
+ return nil
13
+ }
14
return p.New()
15
}
16
0 commit comments