Skip to content

Give Navigate To the counts it sorts equal F# matches by - #20532

Draft
xperiandri wants to merge 4 commits into
dotnet:mainfrom
xperiandri:feature/navigate-to-sort-counts
Draft

xperiandri wants to merge 4 commits into
dotnet:mainfrom
xperiandri:feature/navigate-to-sort-counts

Conversation

@xperiandri

Copy link
Copy Markdown
Contributor

Description

Navigate To (Ctrl+T) orders matches of the same kind by a secondary sort. For C# and VB it puts a match in the file being edited first, then orders by how far the match's folder is from that file, by parameter and type parameter count, and by name. F# results carried no secondary sort, so a name declared both in the file being edited and elsewhere was listed in no particular order.

dotnet/roslyn#85280 has Roslyn compute that key for F# results too, from the active document it already knows, and adds a FSharpNavigateToSearchResult constructor for the two counts. #20531 records the counts on NavigableItem. This passes them on.

Stacked on #20531: the first two commits are that PR.

Checklist

Draft

This cannot build until dotnet/roslyn#85280 has flowed. Against a local build of dotnet/roslyn#85280 and #85281 together, the affected FSharp.Editor.Tests classes pass (145): Navigate To search, persistent cache, loading search and multi-target search, Find All References and multi-target Find All References, semantic classification, Copilot mentions, and the new tests.

🤖 Generated with Claude Code

xperiandri and others added 3 commits September 13, 2026 20:06
Navigate To orders matches that are otherwise equal by these counts for C#
and VB. NavigableItem now carries them: every curried and tupled argument of
the method a declaration compiles to, without the instance and without a
solitary unit argument, and its explicitly declared type parameters.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Navigate To orders matches of the same kind by the folder distance to the
file being edited, then by parameter and type parameter count and name, for
C# and VB. Roslyn computes the same key for F# results once they carry the
counts, which NavigableItem now records.

Needs the FSharpNavigateToSearchResult constructor that takes the counts,
from dotnet/roslyn#85280.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

❗ Release notes required

You can open this PR in browser to add release notes: open in github.dev


✅ Found changes and release notes in following paths:

Warning

No PR link found in some release notes, please consider adding it.

Change path Release notes path Description
`src/Compiler` docs/release-notes/.FSharp.Compiler.Service/11.0.100.md No current pull request URL (#20532) found, please consider adding it
`vsintegration/src` docs/release-notes/.VisualStudio/18.vNext.md

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

@T-Gro T-Gro left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖🕵️ Please shorten the description using this guidance. Focus on the problem and why the change is needed, in simplified technical English. Leave the implementation inventory to the Files tab and retain necessary caveats.

@github-project-automation github-project-automation Bot moved this from New to In Progress in F# Compiler and Tooling Sep 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

2 participants