104 references to IsParentKind
Microsoft.CodeAnalysis.VisualBasic.CodeStyle (88)
CastAnalyzer.vb (6)
138
If speculatedExpressionOuterType Is Nothing OrElse outerSpeculatedExpression.
IsParentKind
(SyntaxKind.SimpleArgument) Then
229
_castNode.WalkUpParentheses().
IsParentKind
(SyntaxKind.Interpolation) Then
259
If outerSpeculatedExpression.
IsParentKind
(SyntaxKind.DirectCastExpression) OrElse
260
outerSpeculatedExpression.
IsParentKind
(SyntaxKind.TryCastExpression) OrElse
261
outerSpeculatedExpression.
IsParentKind
(SyntaxKind.CTypeExpression) Then
266
If expressionToOuterType = Nothing AndAlso outerSpeculatedExpression.
IsParentKind
(SyntaxKind.SimpleArgument) Then
ExpressionSyntaxExtensions.vb (29)
15
While expression.
IsParentKind
(SyntaxKind.ParenthesizedExpression)
38
(expression.
IsParentKind
(SyntaxKind.QualifiedName) AndAlso DirectCast(expression.Parent, QualifiedNameSyntax).Left Is expression) OrElse
39
(expression.
IsParentKind
(SyntaxKind.SimpleMemberAccessExpression) AndAlso DirectCast(expression.Parent, MemberAccessExpressionSyntax).Expression Is expression)
58
Return expression.
IsParentKind
(SyntaxKind.SimpleMemberAccessExpression) AndAlso
80
Return expression.
IsParentKind
(SyntaxKind.QualifiedName) AndAlso
86
Return expression.
IsParentKind
(SyntaxKind.QualifiedName) AndAlso
336
If expression.
IsParentKind
(SyntaxKind.SimpleAssignmentStatement) Then
343
If expression.
IsParentKind
(SyntaxKind.NameColonEquals) AndAlso
344
expression.Parent.
IsParentKind
(SyntaxKind.SimpleArgument) Then
526
If expression.
IsParentKind
(SyntaxKind.EqualsValue) OrElse
527
expression.
IsParentKind
(SyntaxKind.ParenthesizedExpression) OrElse
528
expression.
IsParentKind
(SyntaxKind.SelectStatement) OrElse
529
expression.
IsParentKind
(SyntaxKind.SyncLockStatement) OrElse
530
expression.
IsParentKind
(SyntaxKind.CollectionInitializer) OrElse
531
expression.
IsParentKind
(SyntaxKind.InferredFieldInitializer) OrElse
532
expression.
IsParentKind
(SyntaxKind.BinaryConditionalExpression) OrElse
533
expression.
IsParentKind
(SyntaxKind.TernaryConditionalExpression) OrElse
534
expression.
IsParentKind
(SyntaxKind.ReturnStatement) OrElse
535
expression.
IsParentKind
(SyntaxKind.YieldStatement) OrElse
536
expression.
IsParentKind
(SyntaxKind.XmlEmbeddedExpression) OrElse
537
expression.
IsParentKind
(SyntaxKind.ThrowStatement) OrElse
538
expression.
IsParentKind
(SyntaxKind.IfStatement) OrElse
539
expression.
IsParentKind
(SyntaxKind.WhileStatement) OrElse
540
expression.
IsParentKind
(SyntaxKind.ElseIfStatement) OrElse
541
expression.
IsParentKind
(SyntaxKind.ForEachStatement) OrElse
542
expression.
IsParentKind
(SyntaxKind.ForStatement) OrElse
543
expression.
IsParentKind
(SyntaxKind.ConditionalAccessExpression) OrElse
544
expression.
IsParentKind
(SyntaxKind.TypeOfIsExpression) OrElse
545
expression.
IsParentKind
(SyntaxKind.TypeOfIsNotExpression) Then
InvocationExpressionSyntaxExtensions.vb (3)
45
If invocationExpression.
IsParentKind
(SyntaxKind.CallStatement) OrElse invocationExpression.
IsParentKind
(SyntaxKind.ExpressionStatement) Then
59
If invocationExpression.
IsParentKind
(SyntaxKind.ConditionalAccessExpression) Then
MemberAccessExpressionSyntaxExtensions.vb (1)
59
Return statement.
IsParentKind
(SyntaxKind.ConstructorBlock) AndAlso
ParenthesizedExpressionSyntaxExtensions.vb (7)
138
If node.
IsParentKind
(SyntaxKind.Interpolation) Then
151
If Not node.
IsParentKind
(SyntaxKind.CollectionInitializer) Then
158
If node.Parent.
IsParentKind
(SyntaxKind.ObjectCollectionInitializer) AndAlso
166
If node.Parent.
IsParentKind
(SyntaxKind.CollectionInitializer) AndAlso
167
node.Parent.Parent.
IsParentKind
(SyntaxKind.ObjectCollectionInitializer) AndAlso
211
If node.
IsParentKind
(SyntaxKind.EqualsValue) AndAlso
300
If node.
IsParentKind
(SyntaxKind.InvocationExpression) Then
SemanticModelExtensions.vb (25)
115
If type.
IsParentKind
(SyntaxKind.InheritsStatement) Then
122
If type.
IsParentKind
(SyntaxKind.SimpleAsClause) AndAlso
123
type.Parent.
IsParentKind
(SyntaxKind.VariableDeclarator) Then
124
If type.Parent.Parent.
IsParentKind
(SyntaxKind.FieldDeclaration) OrElse
125
type.Parent.Parent.
IsParentKind
(SyntaxKind.EventStatement) Then
136
If type.
IsParentKind
(SyntaxKind.ObjectCreationExpression) AndAlso
137
type.Parent.
IsParentKind
(SyntaxKind.AsNewClause) AndAlso
138
type.Parent.Parent.
IsParentKind
(SyntaxKind.VariableDeclarator) Then
139
If type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.FieldDeclaration) OrElse
140
type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.EventStatement) Then
149
If type.
IsParentKind
(SyntaxKind.SimpleAsClause) Then
150
If type.Parent.
IsParentKind
(SyntaxKind.DelegateFunctionStatement) OrElse
151
type.Parent.
IsParentKind
(SyntaxKind.FunctionStatement) OrElse
152
type.Parent.
IsParentKind
(SyntaxKind.PropertyStatement) OrElse
153
type.Parent.
IsParentKind
(SyntaxKind.EventStatement) OrElse
154
type.Parent.
IsParentKind
(SyntaxKind.OperatorStatement) Then
160
If type.
IsParentKind
(SyntaxKind.SimpleAsClause) AndAlso
161
type.Parent.
IsParentKind
(SyntaxKind.Parameter) AndAlso
162
type.Parent.Parent.
IsParentKind
(SyntaxKind.ParameterList) Then
163
If type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.DelegateFunctionStatement) OrElse
164
type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.FunctionStatement) OrElse
165
type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.PropertyStatement) OrElse
166
type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.OperatorStatement) OrElse
167
type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.SubNewStatement) OrElse
168
type.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.SubStatement) Then
StatementSyntaxExtensions.vb (1)
744
If statement.
IsParentKind
(SyntaxKind.ConstructorBlock) AndAlso
SyntaxNodeExtensions.vb (1)
816
Return node.
IsParentKind
(SyntaxKind.SimpleAssignmentStatement) AndAlso
VariableDeclaratorSyntaxExtensions.vb (1)
53
If variableDeclarator.
IsParentKind
(SyntaxKind.FieldDeclaration) AndAlso
VisualBasicAddAccessibilityModifiers.vb (4)
67
If member.
IsParentKind
(SyntaxKind.CompilationUnit) OrElse
68
member.
IsParentKind
(SyntaxKind.NamespaceBlock) Then
74
If member.
IsParentKind
(SyntaxKind.ClassBlock) OrElse
75
member.
IsParentKind
(SyntaxKind.ModuleBlock) Then
VisualBasicInferredMemberNameSimplifier.vb (2)
12
If node.NameColonEquals Is Nothing OrElse Not node.
IsParentKind
(SyntaxKind.TupleExpression) Then
38
Dim requiresExplicitNames = parentMemberInitializer.
IsParentKind
(SyntaxKind.ObjectCreationExpression)
VisualBasicSyntaxFacts.vb (7)
163
Return node.
IsParentKind
(SyntaxKind.Attribute) AndAlso
203
Return node.
IsParentKind
(SyntaxKind.SimpleImportsClause) AndAlso
632
Return identifierName.
IsParentKind
(SyntaxKind.NameColonEquals) AndAlso
633
identifierName.Parent.
IsParentKind
(SyntaxKind.SimpleArgument) AndAlso
634
identifierName.Parent.Parent.
IsParentKind
(SyntaxKind.ArgumentList) AndAlso
635
identifierName.Parent.Parent.Parent.
IsParentKind
(SyntaxKind.Attribute)
653
If node.Kind = SyntaxKind.VariableDeclarator AndAlso node.
IsParentKind
(SyntaxKind.FieldDeclaration) Then
VisualBasicUseInferredMemberNameDiagnosticAnalyzer.vb (1)
40
If Not nameColonEquals.
IsParentKind
(SyntaxKind.SimpleArgument) Then
Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes (16)
ExpressionSyntaxExtensions.vb (3)
136
If targetType.ContainsAnonymousType() OrElse expression.
IsParentKind
(SyntaxKind.AsNewClause) Then
197
If Not statement.
IsParentKind
(SyntaxKind.ConstructorBlock) Then
273
Return expression.
IsParentKind
(SyntaxKind.NameOfExpression)
ParameterSyntaxExtensions.vb (1)
15
parameter.
IsParentKind
(SyntaxKind.ParameterList) AndAlso
SimpleNameSyntaxExtensions.vb (1)
36
If simpleName.
IsParentKind
(SyntaxKind.InvocationExpression) Then
VisualBasicTypeInferenceService.TypeInferrer.vb (11)
234
If argumentList.
IsParentKind
(SyntaxKind.ArrayCreationExpression) Then
236
ElseIf argumentList.
IsParentKind
(SyntaxKind.InvocationExpression) Then
286
ElseIf argumentList.
IsParentKind
(SyntaxKind.ObjectCreationExpression) Then
314
ElseIf argumentList.
IsParentKind
(SyntaxKind.Attribute) Then
437
If asClause.
IsParentKind
(SyntaxKind.CatchStatement) Then
602
If equalsValue.
IsParentKind
(SyntaxKind.VariableDeclarator) Then
604
If variableDeclarator.AsClause Is Nothing AndAlso variableDeclarator.
IsParentKind
(SyntaxKind.UsingStatement) Then
626
ElseIf equalsValue.
IsParentKind
(SyntaxKind.PropertyStatement) Then
912
memberAccessExpression.
IsParentKind
(SyntaxKind.InvocationExpression) AndAlso
913
memberAccessExpression.Parent.
IsParentKind
(SyntaxKind.AwaitExpression) Then
932
If ienumerableType IsNot Nothing AndAlso memberAccessExpression.
IsParentKind
(SyntaxKind.InvocationExpression) Then