bpool

package
v4.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 10, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package bpool provides a buffer pool for reusing *bytes.Buffer instances. It reduces memory allocations by recycling buffers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get() *bytes.Buffer

Get returns a buffer from the pool. The buffer is reset before being returned. Callers must call Put when done using the buffer.

func Put

func Put(b *bytes.Buffer)

Put returns a buffer to the pool for reuse.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL