Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions changelog.d/unreleased/3894.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
category: fixed
issues:
- 3894
affected:
- src/CodeIndex/Indexer/References/ReferenceExtractor.Core.cs
- src/CodeIndex/Indexer/References/Languages/CSharpReferenceExtractor.cs
- tests/CodeIndex.Tests/ReferenceExtractorCSharpTests.cs
---

## English

- **C# reference extraction now suppresses common qualified member-call overmatches (#3894)** — `Path.Combine`, `Math.Max`, `string.Join`, `JsonElement.GetString`, and similar receiver-qualified common calls no longer appear as references to unrelated same-name local functions, while direct and `this.` local calls remain indexed.

## 日本語

- **C# 参照抽出で一般的な qualified member call の過剰一致を抑制しました (#3894)** — `Path.Combine`、`Math.Max`、`string.Join`、`JsonElement.GetString` などの receiver 付き共通呼び出しが、同名の無関係なローカル関数への参照として扱われなくなりました。一方で direct call と `this.` 経由のローカル呼び出しは引き続き index されます。
15 changes: 15 additions & 0 deletions changelog.d/unreleased/3912.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
category: fixed
issues:
- 3912
affected:
- tests/CodeIndex.Tests/SymbolExtractorTests.cs
---

## English

- **C# symbol range regression coverage now locks small method spans (#3912)** — regression tests cover C# methods near local functions, lambdas, generic helpers, and later partial-class members so `definition`, `goto`, `symbols --sort size`, and `outline` keep using tight method end lines instead of class-level EOF ranges.

## 日本語

- **小さな C# method の symbol range を固定する回帰テストを追加しました (#3912)** — local function、lambda、generic helper、後続の partial class member の近くにある C# method をカバーし、`definition`、`goto`、`symbols --sort size`、`outline` が class 末尾まで伸びた range ではなく正しい method 終端を使い続けるようにしました。
17 changes: 17 additions & 0 deletions changelog.d/unreleased/3915.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
category: fixed
issues:
- 3915
affected:
- src/CodeIndex/Cli/QueryCommandRunner.cs
- src/CodeIndex/Database/DbSymbolReader.cs
- tests/CodeIndex.Tests/QueryCommandRunnerInspectTests.cs
---

## English

- **`inspect --path --line` now returns exact or enclosing symbols (#3915)** — file-line inspect resolves a symbol on the requested definition line first, then the smallest enclosing symbol for body lines, so JSON results include `definitions`, `nearby_symbols`, and body-capable symbol context instead of only a source excerpt.

## 日本語

- **`inspect --path --line` が exact または enclosing symbol を返すようになりました (#3915)** — file-line inspect は指定行が定義行ならその symbol を優先し、body 行では最小の enclosing symbol を解決するため、JSON 結果が source excerpt だけでなく `definitions`、`nearby_symbols`、body 取得可能な symbol context を含むようになりました。
40 changes: 27 additions & 13 deletions src/CodeIndex/Cli/QueryCommandRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6029,19 +6029,33 @@ public static int RunInspect(string[] cmdArgs, JsonSerializerOptions jsonOptions
var inspectQuery = pathLineInspectMode
? $"{inspectPath}:{options.StartLine!.Value}"
: options.Query!;
var analysis = reader.AnalyzeSymbol(
inspectQuery,
inspectLimit,
options.Lang,
options.IncludeBody,
options.PathPatterns,
options.ExcludePaths,
options.ExcludeTests,
exact,
options.MaxLineWidth,
options.BodyStartLine,
options.BodyLines,
kind: options.Kind);
var analysis = pathLineInspectMode
? reader.AnalyzeFileLine(
inspectPath!,
options.StartLine!.Value,
inspectLimit,
options.Lang,
options.IncludeBody,
options.PathPatterns,
options.ExcludePaths,
options.ExcludeTests,
options.MaxLineWidth,
options.BodyStartLine,
options.BodyLines,
kind: options.Kind)
: reader.AnalyzeSymbol(
inspectQuery,
inspectLimit,
options.Lang,
options.IncludeBody,
options.PathPatterns,
options.ExcludePaths,
options.ExcludeTests,
exact,
options.MaxLineWidth,
options.BodyStartLine,
options.BodyLines,
kind: options.Kind);
var sourceExcerpt = BuildInspectSourceExcerpt(reader, options, analysis, inspectPath);
var sqlGraphSignal = NarrowSqlGraphContractSignal(
reader.GetSqlGraphContractSignal(options.Lang, options.PathPatterns, options.ExcludePaths, options.ExcludeTests),
Expand Down
Loading
Loading