Conversation
src/Features/Core/Portable/CallHierarchy/AbstractCallHierarchyService.cs
Outdated
Show resolved
Hide resolved
| { | ||
| var syntax = await syntaxReference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false); | ||
| if (semanticModel.Language == LanguageNames.VisualBasic && syntax.Parent != null) | ||
| syntax = syntax.Parent; |
There was a problem hiding this comment.
doc - didn't quite understand why this happens for VB?
There was a problem hiding this comment.
If it isn't too complex, I'd prefer if this was something that could be done in the VB impl (with an abstract override) instead of the language check, but won't block on that
src/Features/Core/Portable/CallHierarchy/AbstractCallHierarchyService.cs
Show resolved
Hide resolved
| if (referencedSymbol == null || !SupportsCallHierarchy(referencedSymbol)) | ||
| continue; | ||
|
|
||
| var referencedProject = project.Solution.GetProject(referencedSymbol.ContainingAssembly, cancellationToken) ?? project; |
There was a problem hiding this comment.
Seems a little weird to set the referenced project to the project here - wouldn't that create the wrong symbol key? If we can't find the project should we even create the item (not sure what scenarios will hit this)
There was a problem hiding this comment.
Yeah, I don't know why a project wouldn't be found for the symbol. Will have it just continue.
2b7c3dc to
9e0850b
Compare
9e0850b to
0225eec
Compare
| { | ||
| var syntax = await syntaxReference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false); | ||
| if (semanticModel.Language == LanguageNames.VisualBasic && syntax.Parent != null) | ||
| syntax = syntax.Parent; |
There was a problem hiding this comment.
If it isn't too complex, I'd prefer if this was something that could be done in the VB impl (with an abstract override) instead of the language check, but won't block on that
|
Thank you. You've made a great work ! |
Builds on #82864
Resolves dotnet/vscode-csharp#6297
Resolves #83007
Screen.Recording.2026-03-18.at.9.25.35.PM.mov
Microsoft Reviewers: Open in CodeFlow