libctf: add hash traversal helpers
authorNick Alcock <nick.alcock@oracle.com>
Thu, 27 Jun 2019 12:30:22 +0000 (13:30 +0100)
committerNick Alcock <nick.alcock@oracle.com>
Mon, 1 Jul 2019 10:05:59 +0000 (11:05 +0100)
commit9658dc39630b8ac4e849fb529a53902da5fc2b1f
treedd5246f204e11dd0a90c874ec81dc705f23d58db
parent3e10cffc9872fda4519f76ba487fd108551a179f
libctf: add hash traversal helpers

There are two, ctf_dynhash_iter and ctf_dynhash_iter_remove: the latter
lets you return a nonzero value to remove the element being iterated
over.

Used in the next commit.

libctf/
* ctf-impl.h (ctf_hash_iter_f): New.
(ctf_dynhash_iter): New declaration.
(ctf_dynhash_iter_remove): New declaration.
* ctf-hash.c (ctf_dynhash_iter): Define.
(ctf_dynhash_iter_remove): Likewise.
(ctf_hashtab_traverse): New.
(ctf_hashtab_traverse_remove): Likewise.
(struct ctf_traverse_cb_arg): Likewise.
(struct ctf_traverse_remove_cb_arg): Likewise.
libctf/ChangeLog
libctf/ctf-hash.c
libctf/ctf-impl.h
This page took 0.024732 seconds and 4 git commands to generate.