8 references to GetRequiredParent
Microsoft.CodeAnalysis.CodeStyle.Fixes (1)
AbstractCodeGenerationService_FindDeclaration.cs (1)
182declaration = await SelectFirstOrDefaultAsync(declarations, token.GetRequiredParent().AncestorsAndSelf().Contains, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CSharp.CodeStyle (3)
CSharpVirtualCharService.cs (3)
81return token.GetRequiredParent() is LiteralExpressionSyntax literalExpression 87var parent = token.GetRequiredParent(); 180(parentExpression is InterpolatedStringExpressionSyntax { Contents: var contents } && contents.First() == token.GetRequiredParent());
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (4)
ArrowExpressionClausePlacementCodeFixProvider.cs (1)
61var arrowExpression = (ArrowExpressionClauseSyntax)arrowToken.GetRequiredParent();
ConditionalExpressionPlacementCodeFixProvider.cs (1)
61var conditional = (ConditionalExpressionSyntax)questionToken.GetRequiredParent();
CSharpReplaceDefaultLiteralCodeFixProvider.cs (1)
75var defaultLiteral = (LiteralExpressionSyntax)defaultToken.GetRequiredParent();
UseExplicitTypeCodeFixProvider.cs (1)
117forEach.Identifier.GetRequiredParent(),