Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
CyrusNajmabadi committed Dec 3, 2024
1 parent 7666873 commit 0134be4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@ await TryGetSurroundingNodeSpanAsync<MemberDeclarationSyntax>(renameDefinition.D
if (symbolService is not null)
{
var textSpan = inlineRenameInfo.TriggerSpan;
var semanticModel = await renameDefinition.Document.GetRequiredNullableDisabledSemanticModelAsync(cancellationToken).ConfigureAwait(false);
var (symbol, _, _) = await symbolService.GetSymbolProjectAndBoundSpanAsync(
renameDefinition.Document, textSpan.Start, cancellationToken)
.ConfigureAwait(true);
renameDefinition.Document, semanticModel, textSpan.Start, cancellationToken).ConfigureAwait(true);
var docComment = symbol?.GetDocumentationCommentXml(expandIncludes: true, cancellationToken: cancellationToken);
if (!string.IsNullOrWhiteSpace(docComment))
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,9 @@ protected override NullableFlowState GetNullabilityAnalysis(SemanticModel semant
}

var symbolService = document.GetRequiredLanguageService<IGoToDefinitionSymbolService>();
var semanticModel = await document.GetRequiredSemanticModelAsync(cancellationToken).ConfigureAwait(false);
var (symbol, _, _) = await symbolService.GetSymbolProjectAndBoundSpanAsync(
document, position, cancellationToken).ConfigureAwait(false);
document, semanticModel, position, cancellationToken).ConfigureAwait(false);

// Don't show on-the-fly-docs for namespace symbols.
if (symbol is null || symbol.IsNamespace())
Expand Down

0 comments on commit 0134be4

Please sign in to comment.