3 ms·
> The way you describe go's behavior is "takes snapshot of the underlying data", which usually means "deep copy container". There’s no need for Go to copy anyt
by foldr 5y ago
> The way you describe go's behavior is "takes snapshot of the underlying data", which usually means "deep copy container".
There’s no need for Go to copy anything in the circumstance the OP described. It just doesn’t shrink the underlying array.