MCPcopy Index your code
hub / github.com/evalplus/evalplus / get_function_dependency

Function get_function_dependency

evalplus/sanitize.py:63–74  ·  view source on GitHub ↗
(entrypoint: str, call_graph: Dict[str, str])

Source from the content-addressed store, hash-verified

61
62
63def get_function_dependency(entrypoint: str, call_graph: Dict[str, str]) -> Set[str]:
64 queue = [entrypoint]
65 visited = {entrypoint}
66 while queue:
67 current = queue.pop(0)
68 if current not in call_graph:
69 continue
70 for neighbour in call_graph[current]:
71 if not (neighbour in visited):
72 visited.add(neighbour)
73 queue.append(neighbour)
74 return visited
75
76
77def get_definition_name(node: Node) -> str:

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected