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
When the current AcquireBytes function misses a byte slice in the pool, it will return a byte slice with a length of 0 and a cap of size, and when it hits, it will return a slice with both length and cap of size. I think consistency is more user friendly
Why is this needed:
When the current AcquireBytes function misses a byte slice in the pool, it will return a byte slice with a length of 0 and a cap of size, and when it hits, it will return a slice with both length and cap of size. I think consistency is more user friendly
The text was updated successfully, but these errors were encountered:
@AlexStocks keep consistency is important, but I think should change the size of slice to 0 when hits in pool. Because the user can use it directly without to resize it .
s:=AcquireBytes(128)
s=s[:0] // this is wretcheds=append(s , b)
What would you like to be added:
When the current AcquireBytes function misses a byte slice in the pool, it will return a byte slice with a length of 0 and a cap of size, and when it hits, it will return a slice with both length and cap of size. I think consistency is more user friendly
Why is this needed:
When the current AcquireBytes function misses a byte slice in the pool, it will return a byte slice with a length of 0 and a cap of size, and when it hits, it will return a slice with both length and cap of size. I think consistency is more user friendly
The text was updated successfully, but these errors were encountered: