You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,10 @@ Once you import `github.com/CAFxX/bytespool` you have access to these high-level
12
12
-`GetBytesSlice(size int) []byte` and `PutBytesSlice(b []byte) bool`
13
13
-`GetBytesSlicePtr(size int) *[]byte` and `PutBytesSlicePtr(b *[]byte) bool`
14
14
15
+
In addition, the following utility APIs are available:
16
+
17
+
-`Append` is a replacement for `append` that uses the backing pools to avoid allocations when appending to byte slices.
18
+
15
19
`bytespool` relies on code generation to allow to control the granularity of the backing pools.
16
20
17
21
The [generated code](https://godoc.org/github.com/CAFxX/bytespool) contains specialized versions of all functions for each of the backing pools. These functions can be used to provide a small speed-up if you statically know the desired sizes at compile-time.
0 commit comments