Files
graphify/tests
rajatnagda45 149f55979a fix(go): drop generic type parameters from signature type references
A `[T any]` type parameter is a local binding, not a corpus symbol, but
`_go_collect_type_refs` appended the bare `T`/`R` identifiers used in a
function signature, struct field, or interface method as type references and
ran them through the sourceless-stub path. Every generic function/type in the
corpus then collapsed its `T` onto one bare `t` node — a god node that
pollutes god-node rankings, since single-letter type parameters are not in the
analyzer's builtin-noise filter. TS, C#, and Java already exclude their type
parameters.

A new `_go_type_param_names` helper collects the names a declaration binds
(its own `[T, R]` list and, for a method, the receiver's `Box[T]` arguments —
Go methods reuse the receiver's parameters), and `_go_collect_type_refs` skips
them. Genuine user types and the generic container head (the `Box` in a
`Box[T]` return) still reference.

(cherry picked from commit 434eb689c8)
2026-10-12 22:37:54 +01:00
..