-
Notifications
You must be signed in to change notification settings - Fork 40
Open
12 / 1312 of 13 issues completedLabels
type/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.
Description
Memory leaks caused by slices in Go occur when a small, derived slice (or substring) holds a reference to a large underlying array, preventing the garbage collector from freeing the unused, large memory block. The entire original array remains in memory as long as a single sub-slice points to it.
Starting with 1.22, the new slices package and its Delete function uses clear to allow GC to free data even if it's represented by pointers.
Reactions are currently unavailable
Sub-issues
Metadata
Metadata
Assignees
Labels
type/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.