()
| 12 | } |
| 13 | |
| 14 | func newSafeBuilderPool() *safeBuilderPool { |
| 15 | return &safeBuilderPool{ |
| 16 | pool: sync.Pool{ |
| 17 | New: func() interface{} { |
| 18 | return labels.NewBuilder(labels.New()) |
| 19 | }, |
| 20 | }, |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | func (p *safeBuilderPool) Get() *labels.Builder { |
| 25 | return p.pool.Get().(*labels.Builder) |
no outgoing calls