Changes in common/include/adt/hash_table.h [0db0df2:ad9178bf] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
common/include/adt/hash_table.h
r0db0df2 rad9178bf 60 60 61 61 /** Returns true if the key is equal to the item's lookup key. */ 62 bool (*key_equal)(const void *key, size_t hash,const ht_link_t *item);62 bool (*key_equal)(const void *key, const ht_link_t *item); 63 63 64 64 /** Hash table item removal callback. … … 85 85 member_to_inst((item), type, member) 86 86 87 #define hash_table_foreach(ht, key, member, itype, iterator) \88 for (itype *iterator = NULL; \89 iterator == NULL; iterator = (itype *) INTPTR_MAX) \90 for (ht_link_t *__link = hash_table_find((ht), (key)); \91 __link != NULL && ((iterator = member_to_inst(__link, itype, member))); \92 __link = hash_table_find_next((ht), __link))93 94 87 extern bool hash_table_create(hash_table_t *, size_t, size_t, 95 88 const hash_table_ops_t *); … … 103 96 extern bool hash_table_insert_unique(hash_table_t *, ht_link_t *); 104 97 extern ht_link_t *hash_table_find(const hash_table_t *, const void *); 105 extern ht_link_t *hash_table_find_next(const hash_table_t *, ht_link_t *); 98 extern ht_link_t *hash_table_find_next(const hash_table_t *, ht_link_t *, 99 ht_link_t *); 106 100 extern size_t hash_table_remove(hash_table_t *, const void *); 107 101 extern void hash_table_remove_item(hash_table_t *, ht_link_t *);
Note:
See TracChangeset
for help on using the changeset viewer.