MCPcopy Create free account
hub / github.com/ElementsProject/lightning / intmap_iterate_

Function intmap_iterate_

ccan/ccan/intmap/intmap.c:325–339  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

323}
324
325bool intmap_iterate_(const struct intmap *n,
326 bool (*handle)(intmap_index_t, void *, void *),
327 void *data,
328 intmap_index_t offset)
329{
330 /* Can only happen at root */
331 if (intmap_empty_(n))
332 return true;
333
334 if (n->v)
335 return handle(n->u.i - offset, n->v, data);
336
337 return intmap_iterate_(&n->u.n->child[0], handle, data, offset)
338 && intmap_iterate_(&n->u.n->child[1], handle, data, offset);
339}

Callers

nothing calls this directly

Calls 1

intmap_empty_Function · 0.85

Tested by

no test coverage detected