Get returns a buffer from the pool or creates a new one if the pool is empty.
()
| 14 | // Get returns a buffer from the pool or creates a new one if |
| 15 | // the pool is empty. |
| 16 | func Get() *bytes.Buffer { |
| 17 | b := bpool.Get() |
| 18 | return b.(*bytes.Buffer) |
| 19 | } |
| 20 | |
| 21 | // Put returns a buffer into the pool. |
| 22 | func Put(b *bytes.Buffer) { |
no outgoing calls
no test coverage detected