roslyn icon indicating copy to clipboard operation
roslyn copied to clipboard

Reference highlighting doesn't work from primary constructor base call constructor call

Open Peter-Juhasz opened this issue 1 year ago • 1 comments

Version Used: 17.12.0 P1

Steps to Reproduce:

https://github.com/user-attachments/assets/759db2e2-f427-4d26-a0d4-a5a3e2da9f23

public class A();

public class B() : A$$();

Similar and may be related to #74803

Peter-Juhasz avatar Aug 19 '24 16:08 Peter-Juhasz

It seems that in the example code, INamedTypeSymbol A is returned instead of its constructor, which is why the reference is not found. So there needs to be a breaking change where GetSymbolInfo returns the constructor A() instead of the type itself.

Rekkonnect avatar Oct 18 '24 18:10 Rekkonnect

Fixed with https://github.com/dotnet/roslyn/pull/76097.

CyrusNajmabadi avatar Nov 30 '24 19:11 CyrusNajmabadi