mirror of
https://github.com/fumiama/orbyte.git
synced 2026-06-27 07:20:33 +08:00
fix: ensure atomic alignment
This commit is contained in:
6
item.go
6
item.go
@@ -12,9 +12,11 @@ import (
|
||||
// You must always use the given methods.
|
||||
type Item[T any] struct {
|
||||
pool *Pool[T]
|
||||
cfg any
|
||||
|
||||
stat status
|
||||
// align 64
|
||||
|
||||
cfg any
|
||||
// align 64
|
||||
|
||||
val T
|
||||
}
|
||||
|
||||
@@ -9,8 +9,8 @@ import (
|
||||
|
||||
// UserBuffer with customizable user data structure inside.
|
||||
type UserBuffer[USRDAT any] struct {
|
||||
bytes.Buffer
|
||||
DAT USRDAT
|
||||
bytes.Buffer
|
||||
}
|
||||
|
||||
type bufpooler[USRDAT any] struct{}
|
||||
|
||||
Reference in New Issue
Block a user