Find the first Function/Method node with `name` in a label set. Returns a * borrowed pointer into `funcs` or NULL. */
| 20252 | /* Find the first Function/Method node with `name` in a label set. Returns a |
| 20253 | * borrowed pointer into `funcs` or NULL. */ |
| 20254 | static const cbm_node_t *find_node_named(cbm_node_t *funcs, int count, const char *name) { |
| 20255 | for (int i = 0; i < count; i++) { |
| 20256 | if (strcmp(funcs[i].name, name) == 0) |
| 20257 | return &funcs[i]; |
| 20258 | } |
| 20259 | return NULL; |
| 20260 | } |
| 20261 | |
| 20262 | /* The complexity pass propagates loop_depth along CALLS edges into |
| 20263 | * transitive_loop_depth and flags call-graph cycles as recursive. Caller and |