Skip to content

Carry call-site counts on call edges (callers ≠ call sites) #2010

Description

@uitholland

Problem. Edges are deduplicated per caller function: a function that calls a helper 5 times shows as one edge. For impact analysis ("change this signature — how many places do I touch?") the call-site count is the number that matters. Example from our repo: 186 caller functions vs 303 actual call sites for one security helper — the difference had to come from grep.

Proposal. Store an occurrence count (and ideally line numbers) per call edge during AST extraction, and surface it in explain output (e.g. <-- foo() [calls x3]) and any JSON export. Tree-sitter already visits every call expression, so the data exists at extraction time.

Environment. graphifyy 0.8.36, code-only graph (tree-sitter, no LLM pass), PHP/JS repo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions