Skip to content

Preserve callee call-site columns and spans (#4841) - #4934

Merged
Widthdom merged 6 commits into
mainfrom
fix-issue4841
Jul 27, 2026
Merged

Preserve callee call-site columns and spans (#4841)#4934
Widthdom merged 6 commits into
mainfrom
fix-issue4841

Conversation

@Widthdom

Copy link
Copy Markdown
Owner

Summary

  • persist each reference's physical UTF-16 token width and aggregate a deterministic first callee call site separately from reference_count
  • propagate the retained line, 1-based column, and nullable span through JSON, compact, quickfix, LSP, SARIF, and MCP output
  • preserve raw widths for constructor chains, escaped C# method groups, Java/Kotlin method references, and post-extraction hook clones; legacy or unknown spans remain explicitly imprecise

Root cause

callees aggregated away the reference column and reconstructed no physical span. Output adapters therefore fell back to the start of the line, while normalized reference identities could not reliably recover the source token width.

Validation

  • dotnet build CodeIndex.sln -c Release -p:UseSharedCompilation=false — 0 warnings, 0 errors
  • Issue/review focused tests — 8 passed on net8.0 and 8 passed on net9.0
  • ReferenceExtractor + Database + post-extraction-hook suites — 1,521 passed on net8.0; 1,517 passed and 4 skipped on net9.0
  • full Release suite before the final review corrections — net9.0: 10,110 passed, 419 skipped, 0 failed; net8.0: 10,582 passed, 7 skipped, 1 unrelated concurrent workspace-reload failure (Make extractor registration immutable and workspace-scoped #4602), which passed immediately when rerun in isolation
  • changelog fragment validation and git diff --check passed

Review

Two required Codex adversarial-review rounds were completed. The first found resolved constructor names were being used as source widths; the second found method-group/JVM coordinate normalization and hook-clone propagation gaps. All findings were addressed with regressions.

Documentation and changelog

Fixes #4841

@Widthdom
Widthdom marked this pull request as ready for review July 27, 2026 15:23
@Widthdom
Widthdom merged commit 369ef6e into main Jul 27, 2026
12 checks passed
@Widthdom
Widthdom deleted the fix-issue4841 branch July 27, 2026 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Preserve call-site columns in callees and LSP locations

1 participant