| 203 | } |
| 204 | |
| 205 | void cbm_ht_foreach(const CBMHashTable *ht, cbm_ht_iter_fn fn, void *userdata) { |
| 206 | if (!ht || !fn) |
| 207 | return; |
| 208 | for (cbm_vt_itr itr = cbm_vt_first(&ht->vt); !cbm_vt_is_end(itr); itr = cbm_vt_next(itr)) { |
| 209 | fn(itr.data->key, itr.data->val, userdata); |
| 210 | } |
| 211 | } |
| 212 | |
| 213 | void cbm_ht_clear(CBMHashTable *ht) { |
| 214 | if (!ht) |
no outgoing calls