504 references to GlobalStatement
Microsoft.CodeAnalysis.CSharp (19)
Binder\LocalBinderFactory.cs (1)
127if (member.Kind() == SyntaxKind.GlobalStatement)
Binder\ScriptLocalScopeBinder.cs (1)
84if (member.Kind() != SyntaxKind.GlobalStatement)
Compilation\CSharpCompilation.cs (1)
776var lastGlobalStatement = (GlobalStatementSyntax?)root.Members.LastOrDefault(m => m.IsKind(SyntaxKind.GlobalStatement));
Compilation\MemberSemanticModel.cs (1)
2149case SyntaxKind.GlobalStatement:
Compilation\SyntaxTreeSemanticModel.cs (5)
933case SyntaxKind.GlobalStatement: 1202case SyntaxKind.GlobalStatement: 1454case SyntaxKind.GlobalStatement: 2411return (node) => node.Kind() != SyntaxKind.GlobalStatement || node.Parent != unit; 2416return (node) => node.Parent != unit || node.Kind() == SyntaxKind.GlobalStatement;
Declarations\DeclarationTreeBuilder.cs (2)
80else if (acceptSimpleProgram && member.IsKind(SyntaxKind.GlobalStatement)) 1084case SyntaxKind.GlobalStatement:
Parser\LanguageParser.cs (2)
605case SyntaxKind.GlobalStatement: 2098case SyntaxKind.GlobalStatement:
Symbols\Source\SourceMemberContainerSymbol.cs (1)
4916case SyntaxKind.GlobalStatement:
Symbols\Synthesized\SynthesizedSimpleProgramEntryPointSymbol.cs (2)
282public SyntaxNode ReturnTypeSyntax => CompilationUnit.Members.First(m => m.Kind() == SyntaxKind.GlobalStatement); 288if (member.Kind() == SyntaxKind.GlobalStatement && compilation.IsNullableAnalysisEnabledIn(member))
Syntax\SyntaxFactory.cs (1)
2355if (!lastNode.IsKind(SyntaxKind.GlobalStatement))
Syntax\SyntaxKindFacts.cs (1)
336case SyntaxKind.GlobalStatement:
Syntax\SyntaxNormalizer.cs (1)
1320if (node.Parent.Kind() is SyntaxKind.GlobalStatement or SyntaxKind.FileScopedNamespaceDeclaration)
Microsoft.CodeAnalysis.CSharp.CodeStyle (5)
CSharpSyntaxFacts.cs (1)
712if ((kind != SyntaxKind.GlobalStatement) && (kind != SyntaxKind.IncompleteMember) && (node is MemberDeclarationSyntax))
CSharpSyntaxKinds.cs (1)
153public int? GlobalStatement => (int)SyntaxKind.GlobalStatement;
StatementSyntaxExtensions.cs (2)
40if (first.Parent.IsKind(SyntaxKind.GlobalStatement)) 41return second.Parent.IsKind(SyntaxKind.GlobalStatement);
SyntaxNodeExtensions.cs (1)
533=> node.IsReturnableConstruct() || (node is CompilationUnitSyntax compilationUnit && compilationUnit.Members.Any(SyntaxKind.GlobalStatement));
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (7)
ConvertSwitchStatementToExpressionCodeFixProvider.cs (1)
115editor.RemoveNode(nextStatement.IsParentKind(SyntaxKind.GlobalStatement) ? nextStatement.GetRequiredParent() : nextStatement);
CSharpCodeGenerationService.cs (2)
511var insertionIndex = compilationUnit.Members.LastIndexOf(memberDeclaration => memberDeclaration.IsKind(SyntaxKind.GlobalStatement)) + 1; 515else if (destinationMember is StatementSyntax statement && statement.IsParentKind(SyntaxKind.GlobalStatement))
CSharpDeclarationComparer.cs (1)
148case SyntaxKind.GlobalStatement:
CSharpRemoveUnreachableCodeCodeFixProvider.cs (1)
86&& !statement.IsParentKind(SyntaxKind.GlobalStatement))
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTokenExtensions.cs\SyntaxTokenExtensions.cs (1)
117return statement != null && !statement.IsParentKind(SyntaxKind.GlobalStatement) &&
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs\SyntaxTreeExtensions.cs (1)
1010conditional.Parent.IsParentKind(SyntaxKind.GlobalStatement))
Microsoft.CodeAnalysis.CSharp.Features (18)
CodeRefactorings\ConvertLocalFunctionToMethod\CSharpConvertLocalFunctionToMethodCodeRefactoringProvider.cs (1)
61if (container == null || container.IsKind(SyntaxKind.GlobalStatement))
CodeRefactorings\InlineTemporary\InlineTemporaryCodeRefactoringProvider.cs (1)
284if (scope.IsKind(SyntaxKind.GlobalStatement))
ConvertSwitchStatementToExpressionCodeFixProvider.cs (1)
115editor.RemoveNode(nextStatement.IsParentKind(SyntaxKind.GlobalStatement) ? nextStatement.GetRequiredParent() : nextStatement);
CSharpRemoveUnreachableCodeCodeFixProvider.cs (1)
86&& !statement.IsParentKind(SyntaxKind.GlobalStatement))
Debugging\CSharpProximityExpressionsService.Worker.cs (1)
76if (!memberDeclaration.IsKind(SyntaxKind.GlobalStatement) && !memberDeclaration.GetModifiers().Any(SyntaxKind.StaticKeyword))
Debugging\LocationInfoGetter.cs (1)
32if ((memberDeclaration == null) || (memberDeclaration.Kind() == SyntaxKind.GlobalStatement))
EditAndContinue\CSharpEditAndContinueAnalyzer.cs (5)
787=> node.IsKind(SyntaxKind.GlobalStatement); 1403if (node.IsKind(SyntaxKind.GlobalStatement)) 1446if (node.IsKind(SyntaxKind.GlobalStatement)) 1602case SyntaxKind.GlobalStatement: 1968case SyntaxKind.GlobalStatement:
EditAndContinue\SyntaxComparer.cs (2)
571case SyntaxKind.GlobalStatement: 1086case SyntaxKind.GlobalStatement:
ExtractMethod\CSharpSelectionResult.cs (1)
173Contract.ThrowIfFalse(last.IsParentKind(SyntaxKind.GlobalStatement));
ExtractMethod\CSharpSelectionValidator.cs (1)
103|| selectionInfo.CommonRootFromOriginalSpan.IsParentKind(SyntaxKind.GlobalStatement))
QuickInfo\CSharpSyntacticQuickInfoProvider.cs (1)
103|| parent.IsKind(SyntaxKind.GlobalStatement));
RemoveUnusedVariable\CSharpRemoveUnusedVariableCodeFixProvider.cs (1)
65RemoveNode(editor, node.IsParentKind(SyntaxKind.GlobalStatement) ? node.Parent : node, blockFacts);
Structure\Providers\BlockSyntaxStructureProvider.cs (1)
45autoCollapse: parentKind == SyntaxKind.LocalFunctionStatement && node.Parent.IsParentKind(SyntaxKind.GlobalStatement)));
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (1)
Semantics\TopLevelStatementsTests.cs (1)
6419context.RegisterSyntaxNodeAction(Handle1, SyntaxKind.GlobalStatement);
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (1)
Compilation\SemanticModelGetDeclaredSymbolAPITests.cs (1)
3686var globalStmt = tree.GetCompilationUnitRoot().FindToken(tree.GetCompilationUnitRoot().ToFullString().IndexOf('/')).Parent.AncestorsAndSelf().Single(x => x.IsKind(SyntaxKind.GlobalStatement));
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (440)
IncrementalParsing\IncrementalParsingTests.cs (3)
440SyntaxKind.GlobalStatement, 464SyntaxKind.GlobalStatement, 466SyntaxKind.GlobalStatement,
Parsing\DeclarationParsingTests.cs (3)
8399N(SyntaxKind.GlobalStatement); 8711N(SyntaxKind.GlobalStatement); 9582N(SyntaxKind.GlobalStatement);
Parsing\DeclarationScopeParsingTests.cs (197)
318N(SyntaxKind.GlobalStatement); 343N(SyntaxKind.GlobalStatement); 372N(SyntaxKind.GlobalStatement); 393N(SyntaxKind.GlobalStatement); 435N(SyntaxKind.GlobalStatement); 464N(SyntaxKind.GlobalStatement); 1879N(SyntaxKind.GlobalStatement); 1901N(SyntaxKind.GlobalStatement); 1959N(SyntaxKind.GlobalStatement); 1994N(SyntaxKind.GlobalStatement); 2046N(SyntaxKind.GlobalStatement); 2069N(SyntaxKind.GlobalStatement); 2114N(SyntaxKind.GlobalStatement); 2132N(SyntaxKind.GlobalStatement); 2221N(SyntaxKind.GlobalStatement); 2247N(SyntaxKind.GlobalStatement); 2277N(SyntaxKind.GlobalStatement); 2327N(SyntaxKind.GlobalStatement); 2353N(SyntaxKind.GlobalStatement); 2383N(SyntaxKind.GlobalStatement); 2433N(SyntaxKind.GlobalStatement); 2455N(SyntaxKind.GlobalStatement); 2481N(SyntaxKind.GlobalStatement); 2525N(SyntaxKind.GlobalStatement); 2580N(SyntaxKind.GlobalStatement); 2602N(SyntaxKind.GlobalStatement); 2643N(SyntaxKind.GlobalStatement); 2665N(SyntaxKind.GlobalStatement); 2712N(SyntaxKind.GlobalStatement); 2751N(SyntaxKind.GlobalStatement); 2803N(SyntaxKind.GlobalStatement); 2826N(SyntaxKind.GlobalStatement); 2871N(SyntaxKind.GlobalStatement); 2889N(SyntaxKind.GlobalStatement); 2943N(SyntaxKind.GlobalStatement); 2984N(SyntaxKind.GlobalStatement); 3002N(SyntaxKind.GlobalStatement); 3131N(SyntaxKind.GlobalStatement); 3153N(SyntaxKind.GlobalStatement); 3323N(SyntaxKind.GlobalStatement); 3511N(SyntaxKind.GlobalStatement); 3578N(SyntaxKind.GlobalStatement); 3674N(SyntaxKind.GlobalStatement); 3694N(SyntaxKind.GlobalStatement); 3717N(SyntaxKind.GlobalStatement); 3779N(SyntaxKind.GlobalStatement); 3799N(SyntaxKind.GlobalStatement); 3822N(SyntaxKind.GlobalStatement); 3859N(SyntaxKind.GlobalStatement); 3962N(SyntaxKind.GlobalStatement); 3982N(SyntaxKind.GlobalStatement); 4010N(SyntaxKind.GlobalStatement); 4075N(SyntaxKind.GlobalStatement); 4095N(SyntaxKind.GlobalStatement); 4119N(SyntaxKind.GlobalStatement); 4156N(SyntaxKind.GlobalStatement); 4249N(SyntaxKind.GlobalStatement); 4265N(SyntaxKind.GlobalStatement); 4288N(SyntaxKind.GlobalStatement); 4325N(SyntaxKind.GlobalStatement); 4422N(SyntaxKind.GlobalStatement); 4438N(SyntaxKind.GlobalStatement); 4465N(SyntaxKind.GlobalStatement); 4502N(SyntaxKind.GlobalStatement); 4600N(SyntaxKind.GlobalStatement); 4616N(SyntaxKind.GlobalStatement); 4644N(SyntaxKind.GlobalStatement); 4681N(SyntaxKind.GlobalStatement); 4752N(SyntaxKind.GlobalStatement); 4827N(SyntaxKind.GlobalStatement); 4903N(SyntaxKind.GlobalStatement); 4978N(SyntaxKind.GlobalStatement); 5049N(SyntaxKind.GlobalStatement); 5120N(SyntaxKind.GlobalStatement); 5195N(SyntaxKind.GlobalStatement); 5271N(SyntaxKind.GlobalStatement); 5338N(SyntaxKind.GlobalStatement); 5431N(SyntaxKind.GlobalStatement); 5447N(SyntaxKind.GlobalStatement); 5474N(SyntaxKind.GlobalStatement); 5533N(SyntaxKind.GlobalStatement); 5549N(SyntaxKind.GlobalStatement); 5576N(SyntaxKind.GlobalStatement); 5626N(SyntaxKind.GlobalStatement); 5660N(SyntaxKind.GlobalStatement); 5713N(SyntaxKind.GlobalStatement); 5783N(SyntaxKind.GlobalStatement); 5836N(SyntaxKind.GlobalStatement); 5915N(SyntaxKind.GlobalStatement); 5986N(SyntaxKind.GlobalStatement); 6081N(SyntaxKind.GlobalStatement); 6115N(SyntaxKind.GlobalStatement); 6149N(SyntaxKind.GlobalStatement); 6186N(SyntaxKind.GlobalStatement); 6238N(SyntaxKind.GlobalStatement); 6307N(SyntaxKind.GlobalStatement); 6376N(SyntaxKind.GlobalStatement); 6440N(SyntaxKind.GlobalStatement); 6519N(SyntaxKind.GlobalStatement); 6550N(SyntaxKind.GlobalStatement); 6573N(SyntaxKind.GlobalStatement); 6617N(SyntaxKind.GlobalStatement); 6648N(SyntaxKind.GlobalStatement); 6667N(SyntaxKind.GlobalStatement); 6692N(SyntaxKind.GlobalStatement); 6758N(SyntaxKind.GlobalStatement); 6819N(SyntaxKind.GlobalStatement); 6889N(SyntaxKind.GlobalStatement); 6951N(SyntaxKind.GlobalStatement); 7034N(SyntaxKind.GlobalStatement); 7070N(SyntaxKind.GlobalStatement); 7089N(SyntaxKind.GlobalStatement); 7114N(SyntaxKind.GlobalStatement); 7170N(SyntaxKind.GlobalStatement); 7230N(SyntaxKind.GlobalStatement); 7291N(SyntaxKind.GlobalStatement); 7351N(SyntaxKind.GlobalStatement); 7407N(SyntaxKind.GlobalStatement); 7463N(SyntaxKind.GlobalStatement); 7523N(SyntaxKind.GlobalStatement); 7584N(SyntaxKind.GlobalStatement); 7636N(SyntaxKind.GlobalStatement); 7702N(SyntaxKind.GlobalStatement); 7774N(SyntaxKind.GlobalStatement); 7845N(SyntaxKind.GlobalStatement); 7920N(SyntaxKind.GlobalStatement); 7990N(SyntaxKind.GlobalStatement); 8058N(SyntaxKind.GlobalStatement); 8130N(SyntaxKind.GlobalStatement); 8197N(SyntaxKind.GlobalStatement); 8258N(SyntaxKind.GlobalStatement); 8314N(SyntaxKind.GlobalStatement); 8367N(SyntaxKind.GlobalStatement); 8416N(SyntaxKind.GlobalStatement); 8436N(SyntaxKind.GlobalStatement); 8515N(SyntaxKind.GlobalStatement); 8535N(SyntaxKind.GlobalStatement); 8578N(SyntaxKind.GlobalStatement); 8598N(SyntaxKind.GlobalStatement); 11465N(SyntaxKind.GlobalStatement); 11568N(SyntaxKind.GlobalStatement); 12023N(SyntaxKind.GlobalStatement); 12041N(SyntaxKind.GlobalStatement); 12078N(SyntaxKind.GlobalStatement); 12097N(SyntaxKind.GlobalStatement); 12137N(SyntaxKind.GlobalStatement); 12181N(SyntaxKind.GlobalStatement); 12204N(SyntaxKind.GlobalStatement); 12238N(SyntaxKind.GlobalStatement); 12258N(SyntaxKind.GlobalStatement); 12282N(SyntaxKind.GlobalStatement); 12323N(SyntaxKind.GlobalStatement); 12368N(SyntaxKind.GlobalStatement); 12392N(SyntaxKind.GlobalStatement); 12420N(SyntaxKind.GlobalStatement); 12464N(SyntaxKind.GlobalStatement); 12510N(SyntaxKind.GlobalStatement); 12552N(SyntaxKind.GlobalStatement); 12611N(SyntaxKind.GlobalStatement); 12643N(SyntaxKind.GlobalStatement); 12678N(SyntaxKind.GlobalStatement); 12710N(SyntaxKind.GlobalStatement); 12735N(SyntaxKind.GlobalStatement); 12801N(SyntaxKind.GlobalStatement); 12838N(SyntaxKind.GlobalStatement); 12879N(SyntaxKind.GlobalStatement); 12912N(SyntaxKind.GlobalStatement); 12937N(SyntaxKind.GlobalStatement); 12993N(SyntaxKind.GlobalStatement); 13021N(SyntaxKind.GlobalStatement); 13046N(SyntaxKind.GlobalStatement); 13106N(SyntaxKind.GlobalStatement); 13138N(SyntaxKind.GlobalStatement); 13163N(SyntaxKind.GlobalStatement); 13224N(SyntaxKind.GlobalStatement); 13257N(SyntaxKind.GlobalStatement); 13282N(SyntaxKind.GlobalStatement); 13328N(SyntaxKind.GlobalStatement); 13378N(SyntaxKind.GlobalStatement); 13429N(SyntaxKind.GlobalStatement); 13479N(SyntaxKind.GlobalStatement); 13525N(SyntaxKind.GlobalStatement); 13579N(SyntaxKind.GlobalStatement); 13625N(SyntaxKind.GlobalStatement); 13675N(SyntaxKind.GlobalStatement); 13726N(SyntaxKind.GlobalStatement); 13768N(SyntaxKind.GlobalStatement); 13824N(SyntaxKind.GlobalStatement); 13859N(SyntaxKind.GlobalStatement); 13894N(SyntaxKind.GlobalStatement); 13926N(SyntaxKind.GlobalStatement); 14974N(SyntaxKind.GlobalStatement); 15021N(SyntaxKind.GlobalStatement); 15068N(SyntaxKind.GlobalStatement); 15125N(SyntaxKind.GlobalStatement); 15202N(SyntaxKind.GlobalStatement); 15289N(SyntaxKind.GlobalStatement);
Parsing\DeconstructionTests.cs (11)
1583N(SyntaxKind.GlobalStatement); 1660N(SyntaxKind.GlobalStatement); 1740N(SyntaxKind.GlobalStatement); 2410N(SyntaxKind.GlobalStatement); 2475N(SyntaxKind.GlobalStatement); 2553N(SyntaxKind.GlobalStatement); 2616N(SyntaxKind.GlobalStatement); 2679N(SyntaxKind.GlobalStatement); 2741N(SyntaxKind.GlobalStatement); 2800N(SyntaxKind.GlobalStatement); 2868N(SyntaxKind.GlobalStatement);
Parsing\ExpressionParsingTests.cs (10)
1383N(SyntaxKind.GlobalStatement); 1465N(SyntaxKind.GlobalStatement); 1533N(SyntaxKind.GlobalStatement); 1561N(SyntaxKind.GlobalStatement); 1619N(SyntaxKind.GlobalStatement); 1647N(SyntaxKind.GlobalStatement); 1699N(SyntaxKind.GlobalStatement); 1727N(SyntaxKind.GlobalStatement); 1775N(SyntaxKind.GlobalStatement); 1807N(SyntaxKind.GlobalStatement);
Parsing\FileModifierParsingTests.cs (22)
150N(SyntaxKind.GlobalStatement); 293N(SyntaxKind.GlobalStatement); 356N(SyntaxKind.GlobalStatement); 419N(SyntaxKind.GlobalStatement); 2052N(SyntaxKind.GlobalStatement); 2105N(SyntaxKind.GlobalStatement); 2147N(SyntaxKind.GlobalStatement); 2181N(SyntaxKind.GlobalStatement); 2231N(SyntaxKind.GlobalStatement); 2296N(SyntaxKind.GlobalStatement); 2359N(SyntaxKind.GlobalStatement); 2422N(SyntaxKind.GlobalStatement); 3034N(SyntaxKind.GlobalStatement); 3095N(SyntaxKind.GlobalStatement); 3157N(SyntaxKind.GlobalStatement); 3197N(SyntaxKind.GlobalStatement); 3239N(SyntaxKind.GlobalStatement); 3257N(SyntaxKind.GlobalStatement); 3303N(SyntaxKind.GlobalStatement); 3377N(SyntaxKind.GlobalStatement); 3435N(SyntaxKind.GlobalStatement); 3456N(SyntaxKind.GlobalStatement);
Parsing\FunctionPointerTests.cs (7)
2356N(SyntaxKind.GlobalStatement); 3359N(SyntaxKind.GlobalStatement); 3433N(SyntaxKind.GlobalStatement); 3512N(SyntaxKind.GlobalStatement); 3585N(SyntaxKind.GlobalStatement); 3885N(SyntaxKind.GlobalStatement); 3973N(SyntaxKind.GlobalStatement);
Parsing\LambdaParameterParsingTests.cs (3)
5413N(SyntaxKind.GlobalStatement); 5452N(SyntaxKind.GlobalStatement); 5460N(SyntaxKind.GlobalStatement);
Parsing\LambdaReturnTypeParsingTests.cs (3)
2696N(SyntaxKind.GlobalStatement); 2757N(SyntaxKind.GlobalStatement); 4946N(SyntaxKind.GlobalStatement);
Parsing\MemberDeclarationParsingTests.cs (3)
2276N(SyntaxKind.GlobalStatement); 2294N(SyntaxKind.GlobalStatement); 8657N(SyntaxKind.GlobalStatement);
Parsing\RecordParsing.cs (12)
125N(SyntaxKind.GlobalStatement); 282N(SyntaxKind.GlobalStatement); 1290N(SyntaxKind.GlobalStatement); 1316N(SyntaxKind.GlobalStatement); 1323N(SyntaxKind.GlobalStatement); 2620N(SyntaxKind.GlobalStatement); 2815N(SyntaxKind.GlobalStatement); 2999N(SyntaxKind.GlobalStatement); 3331N(SyntaxKind.GlobalStatement); 3607N(SyntaxKind.GlobalStatement); 3741N(SyntaxKind.GlobalStatement); 3806N(SyntaxKind.GlobalStatement);
Parsing\ScriptParsingTests.cs (88)
103N(SyntaxKind.GlobalStatement); 157N(SyntaxKind.GlobalStatement); 211N(SyntaxKind.GlobalStatement); 315N(SyntaxKind.GlobalStatement); 348N(SyntaxKind.GlobalStatement); 387N(SyntaxKind.GlobalStatement); 425N(SyntaxKind.GlobalStatement); 1158N(SyntaxKind.GlobalStatement); 1208N(SyntaxKind.GlobalStatement); 1337N(SyntaxKind.GlobalStatement); 1419N(SyntaxKind.GlobalStatement); 1456N(SyntaxKind.GlobalStatement); 2008N(SyntaxKind.GlobalStatement); 2616N(SyntaxKind.GlobalStatement); 2648N(SyntaxKind.GlobalStatement); 2680N(SyntaxKind.GlobalStatement); 4564N(SyntaxKind.GlobalStatement); 4605N(SyntaxKind.GlobalStatement); 4649N(SyntaxKind.GlobalStatement); 4701N(SyntaxKind.GlobalStatement); 4753N(SyntaxKind.GlobalStatement); 4802N(SyntaxKind.GlobalStatement); 4851N(SyntaxKind.GlobalStatement); 4901N(SyntaxKind.GlobalStatement); 4959N(SyntaxKind.GlobalStatement); 5017N(SyntaxKind.GlobalStatement); 5078N(SyntaxKind.GlobalStatement); 5147N(SyntaxKind.GlobalStatement); 5199N(SyntaxKind.GlobalStatement); 5259N(SyntaxKind.GlobalStatement); 5321N(SyntaxKind.GlobalStatement); 5391N(SyntaxKind.GlobalStatement); 5467N(SyntaxKind.GlobalStatement); 5545N(SyntaxKind.GlobalStatement); 5626N(SyntaxKind.GlobalStatement); 5721N(SyntaxKind.GlobalStatement); 5811N(SyntaxKind.GlobalStatement); 5860N(SyntaxKind.GlobalStatement); 5916N(SyntaxKind.GlobalStatement); 5965N(SyntaxKind.GlobalStatement); 6024N(SyntaxKind.GlobalStatement); 6088N(SyntaxKind.GlobalStatement); 6175N(SyntaxKind.GlobalStatement); 6228N(SyntaxKind.GlobalStatement); 6343N(SyntaxKind.GlobalStatement); 6400N(SyntaxKind.GlobalStatement); 6449N(SyntaxKind.GlobalStatement); 6495N(SyntaxKind.GlobalStatement); 6547N(SyntaxKind.GlobalStatement); 6607N(SyntaxKind.GlobalStatement); 6676N(SyntaxKind.GlobalStatement); 6751N(SyntaxKind.GlobalStatement); 6820N(SyntaxKind.GlobalStatement); 6882N(SyntaxKind.GlobalStatement); 6952N(SyntaxKind.GlobalStatement); 7022N(SyntaxKind.GlobalStatement); 7092N(SyntaxKind.GlobalStatement); 7162N(SyntaxKind.GlobalStatement); 7232N(SyntaxKind.GlobalStatement); 7302N(SyntaxKind.GlobalStatement); 7376N(SyntaxKind.GlobalStatement); 7459N(SyntaxKind.GlobalStatement); 7536N(SyntaxKind.GlobalStatement); 7592N(SyntaxKind.GlobalStatement); 7663N(SyntaxKind.GlobalStatement); 7737N(SyntaxKind.GlobalStatement); 7801N(SyntaxKind.GlobalStatement); 7902N(SyntaxKind.GlobalStatement); 7971N(SyntaxKind.GlobalStatement); 8084N(SyntaxKind.GlobalStatement); 8139N(SyntaxKind.GlobalStatement); 8209N(SyntaxKind.GlobalStatement); 8285N(SyntaxKind.GlobalStatement); 8363N(SyntaxKind.GlobalStatement); 8828N(SyntaxKind.GlobalStatement); 8884N(SyntaxKind.GlobalStatement); 8944N(SyntaxKind.GlobalStatement); 9004N(SyntaxKind.GlobalStatement); 9068N(SyntaxKind.GlobalStatement); 9119N(SyntaxKind.GlobalStatement); 9189N(SyntaxKind.GlobalStatement); 9208N(SyntaxKind.GlobalStatement); 9247N(SyntaxKind.GlobalStatement); 9304N(SyntaxKind.GlobalStatement); 9361N(SyntaxKind.GlobalStatement); 9419N(SyntaxKind.GlobalStatement); 9616Assert.Equal(SyntaxKind.GlobalStatement, tree.GetCompilationUnitRoot().ChildNodes().ToList()[0].Kind()); 9668Assert.Equal(SyntaxKind.GlobalStatement, statement.Kind());
Parsing\TopLevelStatementsParsingTests.cs (58)
35N(SyntaxKind.GlobalStatement); 67N(SyntaxKind.GlobalStatement); 139N(SyntaxKind.GlobalStatement); 164N(SyntaxKind.GlobalStatement); 189N(SyntaxKind.GlobalStatement); 300N(SyntaxKind.GlobalStatement); 351N(SyntaxKind.GlobalStatement); 415N(SyntaxKind.GlobalStatement); 469N(SyntaxKind.GlobalStatement); 533N(SyntaxKind.GlobalStatement); 623N(SyntaxKind.GlobalStatement); 743N(SyntaxKind.GlobalStatement); 827N(SyntaxKind.GlobalStatement); 903N(SyntaxKind.GlobalStatement); 942N(SyntaxKind.GlobalStatement); 1030N(SyntaxKind.GlobalStatement); 1060N(SyntaxKind.GlobalStatement); 1111N(SyntaxKind.GlobalStatement); 1166N(SyntaxKind.GlobalStatement); 1209N(SyntaxKind.GlobalStatement); 1284N(SyntaxKind.GlobalStatement); 1340N(SyntaxKind.GlobalStatement); 1386N(SyntaxKind.GlobalStatement); 1420N(SyntaxKind.GlobalStatement); 1479N(SyntaxKind.GlobalStatement); 1498N(SyntaxKind.GlobalStatement); 1587N(SyntaxKind.GlobalStatement); 1685N(SyntaxKind.GlobalStatement); 1724N(SyntaxKind.GlobalStatement); 1830N(SyntaxKind.GlobalStatement); 1884N(SyntaxKind.GlobalStatement); 1928N(SyntaxKind.GlobalStatement); 1972N(SyntaxKind.GlobalStatement); 2013N(SyntaxKind.GlobalStatement); 2060N(SyntaxKind.GlobalStatement); 2245N(SyntaxKind.GlobalStatement); 2264N(SyntaxKind.GlobalStatement); 2320N(SyntaxKind.GlobalStatement); 2380N(SyntaxKind.GlobalStatement); 2451N(SyntaxKind.GlobalStatement); 2513N(SyntaxKind.GlobalStatement); 2542N(SyntaxKind.GlobalStatement); 2561N(SyntaxKind.GlobalStatement); 2587N(SyntaxKind.GlobalStatement); 2627N(SyntaxKind.GlobalStatement); 2725N(SyntaxKind.GlobalStatement); 2766N(SyntaxKind.GlobalStatement); 2793N(SyntaxKind.GlobalStatement); 2835N(SyntaxKind.GlobalStatement); 2853N(SyntaxKind.GlobalStatement); 3073N(SyntaxKind.GlobalStatement); 3225N(SyntaxKind.GlobalStatement); 3387N(SyntaxKind.GlobalStatement); 3405N(SyntaxKind.GlobalStatement); 3456N(SyntaxKind.GlobalStatement); 3474N(SyntaxKind.GlobalStatement); 3525N(SyntaxKind.GlobalStatement); 3543N(SyntaxKind.GlobalStatement);
Parsing\UsingDirectiveParsingTests.cs (16)
44N(SyntaxKind.GlobalStatement); 75N(SyntaxKind.GlobalStatement); 114N(SyntaxKind.GlobalStatement); 170N(SyntaxKind.GlobalStatement); 205N(SyntaxKind.GlobalStatement); 259N(SyntaxKind.GlobalStatement); 299N(SyntaxKind.GlobalStatement); 335N(SyntaxKind.GlobalStatement); 417N(SyntaxKind.GlobalStatement); 477N(SyntaxKind.GlobalStatement); 516N(SyntaxKind.GlobalStatement); 575N(SyntaxKind.GlobalStatement); 3486N(SyntaxKind.GlobalStatement); 3543N(SyntaxKind.GlobalStatement); 3596N(SyntaxKind.GlobalStatement); 3643N(SyntaxKind.GlobalStatement);
Syntax\SyntaxTreeTests.cs (4)
1088N(SyntaxKind.GlobalStatement); 1144N(SyntaxKind.GlobalStatement); 1216N(SyntaxKind.GlobalStatement); 1274N(SyntaxKind.GlobalStatement);
Microsoft.CodeAnalysis.CSharp.Workspaces (13)
CodeGeneration\CSharpSyntaxGenerator.cs (3)
2880if (declaration.Parent.IsKind(SyntaxKind.GlobalStatement)) 2919if (declaration.Parent.IsKind(SyntaxKind.GlobalStatement)) 2988if (node.Parent.IsKind(SyntaxKind.GlobalStatement))
CSharpCodeGenerationService.cs (2)
511var insertionIndex = compilationUnit.Members.LastIndexOf(memberDeclaration => memberDeclaration.IsKind(SyntaxKind.GlobalStatement)) + 1; 515else if (destinationMember is StatementSyntax statement && statement.IsParentKind(SyntaxKind.GlobalStatement))
CSharpDeclarationComparer.cs (1)
148case SyntaxKind.GlobalStatement:
CSharpSyntaxFacts.cs (1)
712if ((kind != SyntaxKind.GlobalStatement) && (kind != SyntaxKind.IncompleteMember) && (node is MemberDeclarationSyntax))
CSharpSyntaxKinds.cs (1)
153public int? GlobalStatement => (int)SyntaxKind.GlobalStatement;
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxNodeExtensions.cs\SyntaxNodeExtensions.cs (1)
533=> node.IsReturnableConstruct() || (node is CompilationUnitSyntax compilationUnit && compilationUnit.Members.Any(SyntaxKind.GlobalStatement));
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTokenExtensions.cs\SyntaxTokenExtensions.cs (1)
117return statement != null && !statement.IsParentKind(SyntaxKind.GlobalStatement) &&
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ContextQuery\SyntaxTreeExtensions.cs\SyntaxTreeExtensions.cs (1)
1010conditional.Parent.IsParentKind(SyntaxKind.GlobalStatement))
StatementSyntaxExtensions.cs (2)
40if (first.Parent.IsKind(SyntaxKind.GlobalStatement)) 41return second.Parent.IsKind(SyntaxKind.GlobalStatement);