Skip to content

"Find All References" doesn't show unsaved references #3308

@mattmccutchen-microsoft

Description

@mattmccutchen-microsoft

"Find All References" doesn't seem to show references that have been added to an open file but not saved. This is inconsistent with the behavior for C#, which is to show references based on the latest available version of each file (the editor content if the file is open, otherwise the content on disk). Is this expected?

Repro steps

  1. Create a new F# library and add the following code to the file, but do not save:
type A = int
type B = A
  1. Right-click the first A and choose "Find All References".

Expected behavior

The reference from type B = A is shown.

Actual behavior

"No references found to 'A'".

Known workarounds

Save all files.

Related information

Nightly Visual F# Tools 15.4.1.17070403

Microsoft Visual Studio Enterprise 2017 
Version 15.2 (26430.14) Release
VisualStudio.15.Release/15.2.0+26430.14
Microsoft .NET Framework
Version 4.7.02046

Metadata

Metadata

Assignees

Labels

Area-LangService-FindAllReferencesFind all references across projects and solutionsBugImpact-Medium(Internal MS Team use only) Describes an issue with moderate impact on existing code.

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions