On 02.12.2018 16:41, Bruno Haible wrote: > Hi, > > Darshit Shah wrote: >> I recently tried to use the hash table implementation in gnulib which >> resides in the "hash" module. However, I quickly realised that the hash >> table in gnulib seems to be what is otherwise popularly known as a hash >> set, i.e., it supports storing and retrieving just values from the >> structure. >> >> On the other hand, a hash table is usually expected to have a key->value >> mapping that is stored. > > I agree that the gnulib 'hash' module is just a particular case, and > probably the module name is not very descriptive. > >> Within GNU Wget, we have a fairly portable version of a hash table >> implemented which I think would be a good addition for gnulib. What do you >> think? > > There's not only the one from wget but also the one from gettext and the one > from glib https://gitlab.gnome.org/GNOME/glib/blob/master/glib/ghash.h > https://gitlab.gnome.org/GNOME/glib/blob/master/glib/ghash.c > > and the one from libxml and the ones from CLN and many more. >
There was a hashtable shootout[1] recently, with a followup[2] (although that one is glib-specific): [1]: https://hpjansson.org/blag/2018/07/24/a-hash-table-re-hash/ [2]: https://hpjansson.org/blag/2018/08/29/what-ails-ghashtable/
signature.asc
Description: OpenPGP digital signature