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

Function gossmap_node_idx

common/gossmap.c:199–203  ·  view source on GitHub ↗

Each channel has a unique (low) index. */

Source from the content-addressed store, hash-verified

197
198/* Each channel has a unique (low) index. */
199u32 gossmap_node_idx(const struct gossmap *map, const struct gossmap_node *node)
200{
201 assert(node - map->node_arr < map->num_node_arr);
202 return node - map->node_arr;
203}
204
205u32 gossmap_chan_idx(const struct gossmap *map, const struct gossmap_chan *chan)
206{

Callers 15

get_dijkstraFunction · 0.85
dijkstra_to_hopsFunction · 0.85
new_nodeFunction · 0.85
remove_nodeFunction · 0.85
add_channelFunction · 0.85
gossmap_nth_chanFunction · 0.85
channel_is_betweenFunction · 0.85
channel_is_betweenFunction · 0.85
filter_routehintsFunction · 0.85
init_linear_networkFunction · 0.85
find_path_or_cycleFunction · 0.85
minflowFunction · 0.85

Calls

no outgoing calls

Tested by 2

channel_is_betweenFunction · 0.68
channel_is_betweenFunction · 0.68