The call graph indexer misses call edges originating from anonymous/lambda function bodies. Functions called only from inline closures (e.g., cobra RunE handlers, goroutine literals, callback closures) appear to have zero callers in the graph.
Steps to Reproduce
Given a codebase like:
// cmd/factory.go
func Wire() (*Deps, error) { ... }
// cmd/root.go
var rootCmd = &cobra.Command{
RunE: func(cmd *cobra.Command, args []string) error {
deps, err := Wire() // <-- call from anonymous closure
...
},
}
codegraph_callers("cmd.Wire") → returns "No callers found"
The call graph indexer misses call edges originating from anonymous/lambda function bodies. Functions called only from inline closures (e.g., cobra
RunEhandlers, goroutine literals, callback closures) appear to have zero callers in the graph.Steps to Reproduce
Given a codebase like:
codegraph_callers("cmd.Wire") → returns "No callers found"