util/set: Add a helper to resize a set
authorJason Ekstrand <jason@jlekstrand.net>
Fri, 10 May 2019 18:50:56 +0000 (13:50 -0500)
committerJason Ekstrand <jason@jlekstrand.net>
Mon, 13 May 2019 14:43:47 +0000 (14:43 +0000)
commitbab08c791de323f021bcedbd93aee04343637482
tree4a1e17f9cded00757c177d13f99c66cf8344894d
parentabb450870e8a8fc590e53b21f3ff2a4db42536dd
util/set: Add a helper to resize a set

Often times you don't know how big a set will be and you want the code
to just grow it as needed.  However, sometimes you do know and you can
avoid a lot of rehashing if you just specify a size up-front.

Reviewed-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Thomas Helland <thomashelland90@gmail.com>
src/util/set.c
src/util/set.h