Skip to content

Commit 6f90ffe

Browse files
committed
chore: del testing code
1 parent cb17e53 commit 6f90ffe

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

utils/binary/pool.go

-7
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import (
77
"compress/gzip"
88
"compress/zlib"
99
"sync"
10-
"unsafe"
1110

1211
"github.com/fumiama/orbyte"
1312
"github.com/fumiama/orbyte/pbuf"
@@ -17,12 +16,6 @@ var bufferPool = pbuf.NewBufferPool[teacfg]()
1716

1817
type Builder orbyte.Item[pbuf.UserBuffer[teacfg]]
1918

20-
func init() {
21-
x := *(**orbyte.Pool[pbuf.UserBuffer[teacfg]])(unsafe.Pointer(&bufferPool))
22-
x.SetManualDestroy(true)
23-
x.SetNoPutBack(true)
24-
}
25-
2619
// NewBuilder 从池中取出一个 Builder
2720
func NewBuilder(key ...byte) *Builder {
2821
b := bufferPool.NewBuffer(nil)

0 commit comments

Comments
 (0)