GitNexus/gitnexus/test
Gergo Magyar 8a5478c6f0 fix(cfg): harvest C# out-var and deconstruction-declaration defs (#2195)
Two idiomatic C# write shapes recorded ZERO defs, silently breaking
REACHING_DEF/taint:

- out-var (G(out var n) / G(out int n)) parses as a declaration_expression;
  it was neither declared (phase 1) nor def'd (phase 2), so n resolved to a
  synthetic module binding and the callee-written value had no reaching def.
- deconstruction declaration (var (a, b) = T()) has a variable_declarator whose
  name slot is a tuple_pattern (null name field), so declareVariableDeclaration
  + the variable_declaration walk skipped it entirely (only the assignment form
  (a,b)=T() was handled). Both a and b were dropped.

Declare + def the declaration_expression's identifier (must-def: out params are
definitely-assigned), and route a null-name variable_declarator through the
tuple_pattern via the existing declareForeachTarget/defTupleTargets helpers.
Characterization tests added; csharp suite 42 passed, grammar gate + bench
--check green.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-14 18:49:14 +00:00
..
fixtures fix(cpp): suppress deleted overload winners (#2094) 2026-06-10 18:41:30 +01:00
helpers style(cfg): apply prettier + drop unused imports across the PDG files (#2195) 2026-06-14 17:29:48 +00:00
integration style(cfg): apply prettier + drop unused imports across the PDG files (#2195) 2026-06-14 17:29:48 +00:00
unit fix(cfg): harvest C# out-var and deconstruction-declaration defs (#2195) 2026-06-14 18:49:14 +00:00
utils perf(hooks): cmdline-first Linux db-lock scan, drop the lsof fallback (#2180) (#2183) 2026-06-13 11:52:14 +01:00