deckarep / golang-set

A simple, battle-tested and generic set type for the Go language. Trusted by Docker, 1Password, Ethereum and Hashicorp.
Other
4k stars 272 forks source link

Reintegrating optimizations originally proposed by @fy0 in issue: https://github.com/deckarep/golang-set/issues/60 #113

Closed deckarep closed 1 year ago

deckarep commented 1 year ago

This branch is largely dedicated to an issue that got proposed that I lost track of during the refactor to Generics. Performance gains can be had with the smarter use of capacity hint upon instantiation the sets.

Any takers on CRing this? I'll leave it open for a few days and merge if nobody bites.

Cheers

-deckarep