95 references to ElifDirectiveTrivia
Microsoft.CodeAnalysis.CSharp (18)
Parser\Directives.cs (6)
61
case SyntaxKind.
ElifDirectiveTrivia
:
169
case SyntaxKind.
ElifDirectiveTrivia
:
217
return prev != null && prev.Any() && (prev.Head.Kind == SyntaxKind.IfDirectiveTrivia || prev.Head.Kind == SyntaxKind.
ElifDirectiveTrivia
);
275
case SyntaxKind.
ElifDirectiveTrivia
:
335
case SyntaxKind.
ElifDirectiveTrivia
:
413
case SyntaxKind.
ElifDirectiveTrivia
:
Syntax\CSharpSyntaxTree.cs (2)
241
case SyntaxKind.
ElifDirectiveTrivia
:
260
case SyntaxKind.
ElifDirectiveTrivia
:
Syntax\DirectiveTriviaSyntax.cs (8)
25
case SyntaxKind.
ElifDirectiveTrivia
:
166
case SyntaxKind.
ElifDirectiveTrivia
:
176
case SyntaxKind.
ElifDirectiveTrivia
:
183
case SyntaxKind.
ElifDirectiveTrivia
:
267
case SyntaxKind.
ElifDirectiveTrivia
:
276
case SyntaxKind.
ElifDirectiveTrivia
:
284
case SyntaxKind.
ElifDirectiveTrivia
:
298
case SyntaxKind.
ElifDirectiveTrivia
:
Syntax\SyntaxKindFacts.cs (1)
277
case SyntaxKind.
ElifDirectiveTrivia
:
Syntax\SyntaxNodeRemover.cs (1)
480
case SyntaxKind.
ElifDirectiveTrivia
:
Microsoft.CodeAnalysis.CSharp.CodeStyle (7)
src\Analyzers\CSharp\Analyzers\NewLines\ArrowExpressionClausePlacement\ArrowExpressionClausePlacementDiagnosticAnalyzer.cs (1)
106
SyntaxKind.IfDirectiveTrivia or SyntaxKind.ElseDirectiveTrivia or SyntaxKind.
ElifDirectiveTrivia
or SyntaxKind.EndIfDirectiveTrivia))
src\Analyzers\CSharp\Analyzers\NewLines\ConditionalExpressionPlacement\ConditionalExpressionPlacementDiagnosticAnalyzer.cs (1)
87
SyntaxKind.IfDirectiveTrivia or SyntaxKind.ElseDirectiveTrivia or SyntaxKind.
ElifDirectiveTrivia
or SyntaxKind.EndIfDirectiveTrivia))
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryNullableDirective\CSharpRemoveRedundantNullableDirectiveDiagnosticAnalyzer.cs (1)
110
SyntaxKind.
ElifDirectiveTrivia
or
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryNullableDirective\CSharpRemoveUnnecessaryNullableDirectiveDiagnosticAnalyzer.cs (1)
144
SyntaxKind.
ElifDirectiveTrivia
or
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\DirectiveSyntaxExtensions.cs (1)
69
or SyntaxKind.
ElifDirectiveTrivia
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxNodeExtensions.cs (1)
568
else if (trivia.GetStructure() is (kind: SyntaxKind.ElseDirectiveTrivia or SyntaxKind.
ElifDirectiveTrivia
))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
36
public int ElifDirectiveTrivia => (int)SyntaxKind.
ElifDirectiveTrivia
;
Microsoft.CodeAnalysis.CSharp.Features (7)
ExtractMethod\Extensions.cs (1)
204
case SyntaxKind.
ElifDirectiveTrivia
:
src\Analyzers\CSharp\Analyzers\NewLines\ArrowExpressionClausePlacement\ArrowExpressionClausePlacementDiagnosticAnalyzer.cs (1)
106
SyntaxKind.IfDirectiveTrivia or SyntaxKind.ElseDirectiveTrivia or SyntaxKind.
ElifDirectiveTrivia
or SyntaxKind.EndIfDirectiveTrivia))
src\Analyzers\CSharp\Analyzers\NewLines\ConditionalExpressionPlacement\ConditionalExpressionPlacementDiagnosticAnalyzer.cs (1)
87
SyntaxKind.IfDirectiveTrivia or SyntaxKind.ElseDirectiveTrivia or SyntaxKind.
ElifDirectiveTrivia
or SyntaxKind.EndIfDirectiveTrivia))
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryNullableDirective\CSharpRemoveRedundantNullableDirectiveDiagnosticAnalyzer.cs (1)
110
SyntaxKind.
ElifDirectiveTrivia
or
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryNullableDirective\CSharpRemoveUnnecessaryNullableDirectiveDiagnosticAnalyzer.cs (1)
144
SyntaxKind.
ElifDirectiveTrivia
or
Structure\Providers\DisabledTextTriviaStructureProvider.cs (2)
50
!parentTriviaList[indexInParent - 1].IsKind(SyntaxKind.
ElifDirectiveTrivia
) &&
114
case SyntaxKind.
ElifDirectiveTrivia
:
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (58)
LexicalAndXml\PreprocessorTests.cs (41)
783
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.TrueValue },
807
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.BranchTaken | NodeStatus.TrueValue },
831
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
855
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
879
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.TrueValue },
905
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.BranchTaken | NodeStatus.TrueValue },
930
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
955
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
982
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
983
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.TrueValue },
1010
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
1011
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.BranchTaken | NodeStatus.TrueValue },
1039
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
1040
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
1145
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.TrueValue },
1168
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.BranchTaken | NodeStatus.TrueValue },
1785
SyntaxKind.IfDirectiveTrivia, SyntaxKind.ErrorDirectiveTrivia, SyntaxKind.
ElifDirectiveTrivia
, SyntaxKind.ElseDirectiveTrivia, SyntaxKind.ErrorDirectiveTrivia, SyntaxKind.EndIfDirectiveTrivia,
1810
VerifyDirectives(node, SyntaxKind.IfDirectiveTrivia, SyntaxKind.
ElifDirectiveTrivia
, SyntaxKind.ElseDirectiveTrivia, SyntaxKind.EndIfDirectiveTrivia);
2659
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.NotBranchTaken | NodeStatus.FalseValue },
2724
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive | NodeStatus.BranchTaken | NodeStatus.TrueValue },
3023
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3025
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3027
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3058
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3059
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3060
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3061
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3062
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3063
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3064
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3065
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3066
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3067
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3068
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3069
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3070
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3071
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3097
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3098
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3099
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
3100
new DirectiveInfo { Kind = SyntaxKind.
ElifDirectiveTrivia
, Status = NodeStatus.IsActive },
Syntax\SyntaxNodeTests.cs (17)
372
testContainsHelper1("#if true\r\n#elif true", SyntaxKind.IfDirectiveTrivia, SyntaxKind.
ElifDirectiveTrivia
);
373
testContainsHelper1("#if false\r\n#elif true", SyntaxKind.IfDirectiveTrivia, SyntaxKind.
ElifDirectiveTrivia
);
374
testContainsHelper1("#if false\r\n#elif false", SyntaxKind.IfDirectiveTrivia, SyntaxKind.
ElifDirectiveTrivia
);
1504
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1505
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
1535
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1536
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
1571
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1572
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
1605
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1606
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
1639
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1640
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
1670
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1671
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
1700
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[1].Kind());
1701
Assert.Equal(SyntaxKind.
ElifDirectiveTrivia
, related[2].Kind());
Microsoft.CodeAnalysis.CSharp.Workspaces (5)
Classification\Worker.cs (1)
237
case SyntaxKind.
ElifDirectiveTrivia
:
Classification\Worker_Preprocesser.cs (1)
24
case SyntaxKind.
ElifDirectiveTrivia
:
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\DirectiveSyntaxExtensions.cs (1)
69
or SyntaxKind.
ElifDirectiveTrivia
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxNodeExtensions.cs (1)
568
else if (trivia.GetStructure() is (kind: SyntaxKind.ElseDirectiveTrivia or SyntaxKind.
ElifDirectiveTrivia
))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Services\SyntaxFacts\CSharpSyntaxKinds.cs (1)
36
public int ElifDirectiveTrivia => (int)SyntaxKind.
ElifDirectiveTrivia
;