208 references to Kind
Microsoft.CodeAnalysis.VisualBasic (208)
Analysis\FlowAnalysis\AbstractFlowPass.vb (1)
1829hasCaseElse = hasCaseElse OrElse caseBlock.Syntax.Kind = SyntaxKind.CaseElseBlock
Analysis\FlowAnalysis\ControlFlowPass.vb (1)
169If syntax.Kind = SyntaxKind.GoToStatement Then
Analysis\FlowAnalysis\DataFlowPass.vb (1)
2029If syntax IsNot Nothing AndAlso syntax.Kind = SyntaxKind.VariableDeclarator Then
Binding\AttributeSemanticModel.vb (1)
57Select Case node.Kind
Binding\Binder_Attributes.vb (1)
802If node.Syntax.Kind = SyntaxKind.PredefinedCastExpression Then
Binding\Binder_Conversions.vb (3)
468(TypeOf argument.Syntax.Parent Is AssignmentStatementSyntax AndAlso argument.Syntax.Parent.Kind <> SyntaxKind.SimpleAssignmentStatement), 1260warnIfResultOfAsyncMethodIsDroppedDueToRelaxation:=Not isExplicit AndAlso tree.Kind <> SyntaxKind.ObjectCreationExpression) 1484warnIfResultOfAsyncMethodIsDroppedDueToRelaxation:=Not isExplicit AndAlso tree.Kind <> SyntaxKind.ObjectCreationExpression,
Binding\Binder_Delegates.vb (3)
573If addressOfOperandSyntax.Kind = SyntaxKind.AddressOfExpression Then 630If addressOfOperandSyntax.Kind = SyntaxKind.AddressOfExpression Then 996If addressOfOperandSyntax.Kind = SyntaxKind.AddressOfExpression Then
Binding\Binder_Expressions.vb (3)
3653node.Parent.Kind <> SyntaxKind.NamedFieldInitializer Then 3698parent.Kind = SyntaxKind.SimpleMemberAccessExpression AndAlso 3705syntax.Parent.Kind = SyntaxKind.NameOfExpression AndAlso
Binding\Binder_Initializers.vb (3)
295If equalsValueOrAsNewSyntax.Kind() = SyntaxKind.AsNewClause Then 317If equalsValueOrAsNewSyntax.Kind = SyntaxKind.AsNewClause Then 401If equalsValueOrAsNewSyntax.Kind = SyntaxKind.AsNewClause Then
Binding\Binder_Invocation.vb (4)
1316Select Case result.Kind 1487If node.Kind = SyntaxKind.IdentifierName AndAlso 1489node.Parent.Kind = SyntaxKind.NamedFieldInitializer AndAlso 3283Select Case syntax.Kind
Binding\Binder_Statements.vb (1)
628If Not node.WasCompilerGenerated AndAlso node.Syntax.Kind = SyntaxKind.LabelStatement AndAlso
Binding\Binder_Utils.vb (1)
761Select Case node.Kind
Binding\BinderFactory.BinderFactoryVisitor.vb (1)
85If _factory.InScript AndAlso node.Parent.Kind = SyntaxKind.CompilationUnit Then
Binding\BinderFactory.vb (2)
49node.Kind = SyntaxKind.CompilationUnit Then 113If node.Kind = SyntaxKind.DocumentationCommentTrivia Then
Binding\ExecutableCodeBinder.vb (1)
55Select Case _syntaxRoot.Kind
Binding\InitializerSemanticModel.vb (5)
42Select Case node.Kind 107If initializer.Kind = SyntaxKind.EqualsValue Then 147If initializer.Kind = SyntaxKind.EqualsValue Then 169If rootSyntax.Kind = SyntaxKind.FieldDeclaration Then 189ElseIf rootSyntax.Kind = SyntaxKind.PropertyStatement Then
Binding\MemberSemanticModel.vb (22)
1270If current.Kind = SyntaxKind.DocumentationCommentTrivia Then 1291If current.Kind = SyntaxKind.MultiLineFunctionLambdaExpression OrElse current.Kind = SyntaxKind.MultiLineSubLambdaExpression Then 1306ElseIf current.Kind = SyntaxKind.MultiLineFunctionLambdaExpression OrElse current.Kind = SyntaxKind.MultiLineSubLambdaExpression Then 1312ElseIf current.Kind = SyntaxKind.SingleLineSubLambdaExpression Then 1335Debug.Assert(current.Parent.Kind = SyntaxKind.WithStatement) 1336Debug.Assert(current.Parent.Parent.Kind = SyntaxKind.WithBlock) 1374Select Case node.Kind 1705If (node.Kind = SyntaxKind.InferredFieldInitializer OrElse node.Kind = SyntaxKind.NamedFieldInitializer) AndAlso 1706node.Parent IsNot Nothing AndAlso node.Parent.Kind = SyntaxKind.ObjectMemberInitializer AndAlso 1707node.Parent.Parent IsNot Nothing AndAlso node.Parent.Parent.Kind = SyntaxKind.AnonymousObjectCreationExpression Then 1912If syntax.Kind = SyntaxKind.CollectionInitializer AndAlso parent IsNot Nothing Then 1913If parent.Kind = SyntaxKind.ObjectCollectionInitializer Then 1915ElseIf parent.Kind = SyntaxKind.CollectionInitializer Then 1917Return parent IsNot Nothing AndAlso parent.Kind = SyntaxKind.ObjectCollectionInitializer 1953Debug.Assert(bindingRoot.Kind = SyntaxKind.FieldDeclaration OrElse 1954bindingRoot.Kind = SyntaxKind.PropertyStatement OrElse 1955bindingRoot.Kind = SyntaxKind.Parameter OrElse 1956bindingRoot.Kind = SyntaxKind.EnumMemberDeclaration OrElse 1982If node.Kind = SyntaxKind.DocumentationCommentTrivia Then
BoundTree\BoundAssignmentOperator.vb (1)
93(Type.IsVoidType() AndAlso Syntax.Kind = SyntaxKind.MidAssignmentStatement) OrElse
BoundTree\BoundLambda.vb (1)
22Dim kind As SyntaxKind = Me.Syntax.Kind
BoundTree\UnboundLambda.vb (2)
30Dim kind As SyntaxKind = Me.Syntax.Kind 43Dim kind As SyntaxKind = Me.Syntax.Kind
CodeGen\EmitStatement.vb (1)
1029Debug.Assert(caseBlock.Syntax.Kind = SyntaxKind.CaseElseBlock)
Compilation\DocumentationComments\DocumentationCommentWalker.vb (1)
137Dim kind As SyntaxKind = node.Kind()
Compilation\SemanticModel.vb (5)
932boundNodes.LowestBoundNodeOfSyntacticParent.Syntax.Kind = SyntaxKind.ObjectCreationExpression AndAlso 999((parentSyntax.Kind = SyntaxKind.ObjectCreationExpression AndAlso (DirectCast(parentSyntax, ObjectCreationExpressionSyntax).Type Is boundNodes.LowestBoundNode.Syntax))) Then 1038boundNodes.LowestBoundNodeOfSyntacticParent.Syntax.Kind = SyntaxKind.ObjectCreationExpression AndAlso 1146If lowestExpr.Kind = BoundKind.BadExpression AndAlso lowestExpr.Syntax.Kind = SyntaxKind.ObjectCreationExpression Then 1430parentSyntax.Kind = SyntaxKind.Attribute AndAlso
Compilation\VisualBasicCompilation.vb (1)
2322Dim getKind As Func(Of SyntaxNode, SyntaxKind) = Function(node As SyntaxNode) node.Kind
Declarations\MergedTypeDeclaration.vb (2)
86Select Case node.Kind 101Throw ExceptionUtilities.UnexpectedValue(node.Kind)
Lowering\Instrumentation\CodeCoverageInstrumenter.vb (1)
521Select Case syntax.Kind()
Lowering\Instrumentation\DebugInfoInjector.vb (3)
200Select Case original.Syntax.Kind 225Select Case original.Syntax.Kind 246Select Case original.AlternativeOpt.Syntax.Kind
Lowering\Instrumentation\DebugInfoInjector_SequencePoints.vb (1)
154Debug.Assert(syntax.Parent.Kind = SyntaxKind.VariableDeclarator)
Lowering\Instrumentation\Instrumenter.vb (36)
133Debug.Assert(original.Syntax.Kind = SyntaxKind.SyncLockBlock) 139Debug.Assert(original.Syntax.Kind = SyntaxKind.SyncLockBlock) 148Debug.Assert(original.Syntax.Kind = SyntaxKind.SyncLockBlock) 157Debug.Assert(original.Syntax.Kind = SyntaxKind.SyncLockBlock) 166Debug.Assert(original.Syntax.Kind = SyntaxKind.WhileBlock) 172Debug.Assert(original.Syntax.Kind = SyntaxKind.WhileBlock) 187Debug.Assert(original.Syntax.Kind = SyntaxKind.ForEachBlock) 193Debug.Assert(original.Syntax.Kind = SyntaxKind.MultiLineIfBlock OrElse original.Syntax.Kind = SyntaxKind.ElseIfBlock OrElse original.Syntax.Kind = SyntaxKind.SingleLineIfStatement) 199Debug.Assert(original.Syntax.Kind = SyntaxKind.MultiLineIfBlock) 208Debug.Assert(original.Syntax.Kind = SyntaxKind.MultiLineIfBlock OrElse original.Syntax.Kind = SyntaxKind.ElseIfBlock OrElse original.Syntax.Kind = SyntaxKind.SingleLineIfStatement) 217Debug.Assert(original.AlternativeOpt.Syntax.Kind = SyntaxKind.ElseBlock) 218Debug.Assert(original.AlternativeOpt.Syntax.Parent.Kind = SyntaxKind.MultiLineIfBlock) 227Debug.Assert(original.AlternativeOpt.Syntax.Kind = SyntaxKind.ElseBlock OrElse original.AlternativeOpt.Syntax.Kind = SyntaxKind.SingleLineElseClause) 263Debug.Assert(original.Syntax.Kind = SyntaxKind.CatchBlock) 276Debug.Assert(original.Syntax.Kind = SyntaxKind.CatchBlock) 286Debug.Assert(original.Syntax.Kind = SyntaxKind.TryBlock) 288Debug.Assert(original.FinallyBlockOpt.Syntax.Kind = SyntaxKind.FinallyBlock) 297Debug.Assert(original.Syntax.Kind = SyntaxKind.TryBlock) 303Debug.Assert(original.Syntax.Kind = SyntaxKind.TryBlock) 336Debug.Assert(original.Syntax.Kind = SyntaxKind.SelectBlock) 350Debug.Assert(original.Syntax.Kind = SyntaxKind.ForEachBlock) 360Debug.Assert(original.Syntax.Kind = SyntaxKind.ForEachBlock) 366Debug.Assert(original.Syntax.Kind = SyntaxKind.ForBlock) 372Debug.Assert(original.Syntax.Kind = SyntaxKind.ForBlock) 378Debug.Assert(original.Syntax.Kind = SyntaxKind.ModifiedIdentifier) 379Debug.Assert(original.Syntax.Parent.Kind = SyntaxKind.VariableDeclarator) 388Debug.Assert(original.Syntax.Kind = SyntaxKind.UsingBlock) 394Debug.Assert(original.Syntax.Kind = SyntaxKind.UsingBlock) 403Debug.Assert(original.Syntax.Kind = SyntaxKind.UsingBlock) 412Debug.Assert(original.Syntax.Kind = SyntaxKind.WithBlock) 421Debug.Assert(original.Syntax.Kind = SyntaxKind.WithBlock)
Lowering\LambdaRewriter\LambdaFrame.vb (2)
114Select Case syntaxOpt.Kind() 120ExceptionUtilities.UnexpectedValue(syntaxOpt.Kind())
Lowering\LambdaRewriter\LambdaRewriter.vb (2)
1281Select Case curSyntax.Kind 1391Select Case node.Syntax.Kind
Lowering\LocalRewriter\LocalRewriter.vb (3)
301node.Syntax.Kind <> SyntaxKind.GroupAggregation AndAlso 302((node.Syntax.Kind = SyntaxKind.SimpleAsClause AndAlso node.Syntax.Parent.Kind = SyntaxKind.CollectionRangeVariable) OrElse
Lowering\LocalRewriter\LocalRewriter_AsNewLocalDeclarations.vb (1)
54Debug.Assert(node.Syntax.Kind = SyntaxKind.VariableDeclarator)
Lowering\LocalRewriter\LocalRewriter_If.vb (8)
42Select Case syntax.Kind 55Throw ExceptionUtilities.UnexpectedValue(syntax.Kind) 69If syntax.Kind <> SyntaxKind.SingleLineIfStatement Then 146Select Case instrumentationTargetOpt.Syntax.Kind 154Throw ExceptionUtilities.UnexpectedValue(instrumentationTargetOpt.Syntax.Kind) 157If instrumentationTargetOpt.Syntax.Kind = SyntaxKind.MultiLineIfBlock Then 190Select Case instrumentationTargetOpt.Syntax.Kind 198Throw ExceptionUtilities.UnexpectedValue(instrumentationTargetOpt.Syntax.Kind)
Lowering\LocalRewriter\LocalRewriter_Label.vb (1)
21Not node.WasCompilerGenerated AndAlso node.Syntax.Kind = SyntaxKind.LabelStatement Then
Lowering\LocalRewriter\LocalRewriter_SelectCase.vb (4)
285Debug.Assert(curCaseBlock.Syntax.Kind = SyntaxKind.CaseElseBlock) 298Debug.Assert(curCaseBlock.Syntax.Kind = SyntaxKind.CaseBlock) 325Debug.Assert(node.Syntax.Kind = SyntaxKind.CaseStatement) 333Debug.Assert(node.Syntax.Kind = SyntaxKind.CaseElseStatement)
Lowering\LocalRewriter\LocalRewriter_SyncLock.vb (1)
182If syntaxNode.Parent.Kind = SyntaxKind.SyncLockStatement Then
Lowering\LocalRewriter\LocalRewriter_Throw.vb (1)
23Debug.Assert(node.Syntax.Kind = SyntaxKind.ErrorStatement, "Must be an Error statement.")
Lowering\LocalRewriter\LocalRewriter_UnstructuredExceptionHandling.vb (13)
480If statement.Syntax.Parent IsNot Nothing AndAlso statement.Syntax.Parent.Kind = SyntaxKind.EraseStatement Then 483Select Case statement.Syntax.Kind 497statement.Syntax.Parent.Kind <> SyntaxKind.VariableDeclarator OrElse 499statement.Syntax.Parent.Parent.Kind <> SyntaxKind.LocalDeclarationStatement Then 524Debug.Assert(statement.Syntax.Kind = SyntaxKind.ElseIfBlock AndAlso 526statement.Syntax.Parent.Kind = SyntaxKind.MultiLineIfBlock AndAlso 530Debug.Assert((statement.Syntax.Kind = SyntaxKind.CaseBlock OrElse statement.Syntax.Kind = SyntaxKind.CaseElseBlock) AndAlso 532statement.Syntax.Parent.Kind = SyntaxKind.SelectBlock AndAlso 536Debug.Assert(statement.Syntax.Kind = SyntaxKind.ModifiedIdentifier AndAlso 538statement.Syntax.Parent.Kind = SyntaxKind.VariableDeclarator AndAlso 540statement.Syntax.Parent.Parent.Kind = SyntaxKind.LocalDeclarationStatement) 543Debug.Assert((statement.Syntax.Kind = SyntaxKind.RedimClause AndAlso
Lowering\LocalRewriter\LocalRewriter_With.vb (1)
68Dim instrument As Boolean = Me.Instrument(node) AndAlso syntax.Kind = SyntaxKind.WithBlock
Lowering\StateMachineRewriter\StateMachineRewriter.StateMachineMethodToClassRewriter.vb (1)
180SyntaxBindingUtilities.BindsToTryStatement(node), $"Unexpected syntax: {node.Kind()}")
Scanner\Blender.vb (2)
118If node.Kind = SyntaxKind.CompilationUnit OrElse IsStatementLike(node) Then 132Select Case node.Kind
Semantics\OverloadResolution.vb (1)
3418If parent.Kind = SyntaxKind.Attribute Then
src\Compilers\VisualBasic\BasicAnalyzerDriver\VisualBasicDeclarationComputer.vb (1)
56Select Case node.Kind()
Syntax\InternalSyntax\SyntaxNode.vb (1)
237If element.Kind = SyntaxKind.JoinCondition Then
Syntax\LambdaUtilities.vb (16)
17Select Case node.Kind 75Select Case oldLambda.Kind 94Throw ExceptionUtilities.UnexpectedValue(oldLambda.Kind) 125Select Case parent.Kind 313Select Case node.Kind 362Select Case lambda.Kind 383Select Case clause.Kind 399Throw ExceptionUtilities.UnexpectedValue(clause.Kind) 404Select Case clause.Kind 419Throw ExceptionUtilities.UnexpectedValue(clause.Kind) 433Throw ExceptionUtilities.UnexpectedValue(lambda.Kind) 489Select Case node.Kind 540Select Case clause.Kind() 586Select Case clause.Kind 598Throw ExceptionUtilities.UnexpectedValue(clause.Kind) 637Select Case node.Kind()
Syntax\SyntaxFacts.vb (10)
167Select Case parent.Kind() 242Select Case possibleLambda.Kind() 298Select Case possibleBlock.Kind 338Select Case possibleBlock.Kind() 638Select Case nextNode.Kind() 668If node.Kind <> SyntaxKind.IdentifierName Then 806Dim parentKind = token.Parent.Kind 869token.Parent.Parent.Kind = SyntaxKind.NamedFieldInitializer 1045Dim parentKind = token.Parent.Kind 1163Select Case parent.Kind()
Syntax\SyntaxNodeExtensions.vb (3)
87Select Case this.Kind 323Select Case syntax.Kind 371Throw ExceptionUtilities.UnexpectedValue(syntax.Kind)
Syntax\SyntaxNormalizer.vb (25)
212Not (trivia.Kind = SyntaxKind.ColonTrivia AndAlso tokenParent IsNot Nothing AndAlso tokenParent.Kind = SyntaxKind.LabelStatement) AndAlso 213Not (tokenParent IsNot Nothing AndAlso tokenParent.Parent IsNot Nothing AndAlso tokenParent.Parent.Kind = SyntaxKind.CrefReference) AndAlso 423If nextToken.Parent.Kind = SyntaxKind.SingleLineFunctionLambdaExpression Then 462If (token.Kind = SyntaxKind.CommaToken AndAlso (nextToken.Kind = SyntaxKind.EmptyToken OrElse token.Parent.Kind = SyntaxKind.InterpolationAlignmentClause)) OrElse 470ElseIf nextToken.Kind = SyntaxKind.DotToken AndAlso nextToken.Parent.Kind <> SyntaxKind.NamedFieldInitializer Then 475If token.Parent.Kind = SyntaxKind.LabelStatement Then 479ElseIf nextToken.Parent.Kind = SyntaxKind.InterpolationFormatClause Then 498If SyntaxFacts.IsRelationalCaseClause(token.Parent.Kind()) OrElse 499SyntaxFacts.IsRelationalCaseClause(nextToken.Parent.Kind()) Then 506token.Parent.Kind = SyntaxKind.AttributeList) Then 521If token.Kind = SyntaxKind.ColonToken AndAlso token.Parent.Kind = SyntaxKind.XmlPrefix OrElse 522nextToken.Kind = SyntaxKind.ColonToken AndAlso nextToken.Parent.Kind = SyntaxKind.XmlPrefix Then 549If token.Kind = SyntaxKind.ColonToken AndAlso token.Parent.Kind = SyntaxKind.AttributeTarget OrElse 550nextToken.Kind = SyntaxKind.ColonToken AndAlso nextToken.Parent.Kind = SyntaxKind.AttributeTarget Then 556(token.Parent.Kind = SyntaxKind.XmlAttribute OrElse 557token.Parent.Kind = SyntaxKind.XmlCrefAttribute OrElse 558token.Parent.Kind = SyntaxKind.XmlNameAttribute OrElse 559token.Parent.Kind = SyntaxKind.XmlDeclaration)) OrElse 561(nextToken.Parent.Kind = SyntaxKind.XmlAttribute OrElse 562nextToken.Parent.Kind = SyntaxKind.XmlCrefAttribute OrElse 563nextToken.Parent.Kind = SyntaxKind.XmlNameAttribute OrElse 564nextToken.Parent.Kind = SyntaxKind.XmlDeclaration)) Then 576If token.Kind = SyntaxKind.AtToken AndAlso token.Parent.Kind = SyntaxKind.XmlAttributeAccessExpression Then 597If token.Parent.Kind = SyntaxKind.RegionDirectiveTrivia AndAlso 690If listElement.Kind = SyntaxKind.LabelStatement Then
Syntax\VisualBasicSyntaxRewriter.vb (1)
86If alternate IsNot Nothing AndAlso visited IsNot Nothing AndAlso visited.Kind <> SyntaxKind.None Then
Syntax\VisualBasicSyntaxTree.vb (1)
387If Not SyntaxFacts.IsXmlSyntax(node.Kind()) Then