7 references to GetAncestorsOrThis
Microsoft.CodeAnalysis.Workspaces (7)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SyntaxNodeExtensions.cs (3)
79
return node?.
GetAncestorsOrThis
<TNode>().FirstOrDefault();
174
return node.
GetAncestorsOrThis
<SyntaxNode>().Contains(child);
184
set.AddRange(node2.
GetAncestorsOrThis
<SyntaxNode>());
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\AddImports\AbstractAddImportsService.cs (2)
71
return applicableContainer.
GetAncestorsOrThis
<SyntaxNode>().ToImmutableArray();
169
var contextSpine = applicableContainer.
GetAncestorsOrThis
<SyntaxNode>().ToImmutableArray();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (1)
186
var blocks = state.InnermostBlock.
GetAncestorsOrThis
<SyntaxNode>();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.State.cs (1)
127
expr => expr.
GetAncestorsOrThis
<TStatementSyntax>()));