115 references to TerminatorState
Microsoft.CodeAnalysis.CSharp (115)
Parser\LanguageParser.cs (109)
33
private
TerminatorState
_termState; // Resettable
93
private const int LastTerminatorState = (int)
TerminatorState
.IsPatternInSwitchExpressionArm;
104
switch (_termState & (
TerminatorState
)i)
106
case
TerminatorState
.IsNamespaceMemberStartOrStop when this.IsNamespaceMemberStartOrStop():
107
case
TerminatorState
.IsAttributeDeclarationTerminator when this.IsAttributeDeclarationTerminator():
108
case
TerminatorState
.IsPossibleAggregateClauseStartOrStop when this.IsPossibleAggregateClauseStartOrStop():
109
case
TerminatorState
.IsPossibleMemberStartOrStop when this.IsPossibleMemberStartOrStop():
110
case
TerminatorState
.IsEndOfReturnType when this.IsEndOfReturnType():
111
case
TerminatorState
.IsEndOfParameterList when this.IsEndOfParameterList():
112
case
TerminatorState
.IsEndOfFieldDeclaration when this.IsEndOfFieldDeclaration():
113
case
TerminatorState
.IsPossibleEndOfVariableDeclaration when this.IsPossibleEndOfVariableDeclaration():
114
case
TerminatorState
.IsEndOfTypeArgumentList when this.IsEndOfTypeArgumentList():
115
case
TerminatorState
.IsPossibleStatementStartOrStop when this.IsPossibleStatementStartOrStop():
116
case
TerminatorState
.IsEndOfFixedStatement when this.IsEndOfFixedStatement():
117
case
TerminatorState
.IsEndOfTryBlock when this.IsEndOfTryBlock():
118
case
TerminatorState
.IsEndOfCatchClause when this.IsEndOfCatchClause():
119
case
TerminatorState
.IsEndOfFilterClause when this.IsEndOfFilterClause():
120
case
TerminatorState
.IsEndOfCatchBlock when this.IsEndOfCatchBlock():
121
case
TerminatorState
.IsEndOfDoWhileExpression when this.IsEndOfDoWhileExpression():
122
case
TerminatorState
.IsEndOfForStatementArgument when this.IsEndOfForStatementArgument():
123
case
TerminatorState
.IsEndOfDeclarationClause when this.IsEndOfDeclarationClause():
124
case
TerminatorState
.IsEndOfArgumentList when this.IsEndOfArgumentList():
125
case
TerminatorState
.IsSwitchSectionStart when this.IsPossibleSwitchSection():
126
case
TerminatorState
.IsEndOfTypeParameterList when this.IsEndOfTypeParameterList():
127
case
TerminatorState
.IsEndOfMethodSignature when this.IsEndOfMethodSignature():
128
case
TerminatorState
.IsEndOfNameInExplicitInterface when this.IsEndOfNameInExplicitInterface():
129
case
TerminatorState
.IsEndOfFunctionPointerParameterList when this.IsEndOfFunctionPointerParameterList(errored: false):
130
case
TerminatorState
.IsEndOfFunctionPointerParameterListErrored when this.IsEndOfFunctionPointerParameterList(errored: true):
131
case
TerminatorState
.IsEndOfFunctionPointerCallingConvention when this.IsEndOfFunctionPointerCallingConvention():
132
case
TerminatorState
.IsEndOfRecordOrClassOrStructOrInterfaceSignature when this.IsEndOfRecordOrClassOrStructOrInterfaceSignature():
575
var
saveTerm = _termState;
576
_termState |=
TerminatorState
.IsNamespaceMemberStartOrStop;
1069
var
saveTerm = _termState;
1070
_termState |=
TerminatorState
.IsAttributeDeclarationTerminator;
1732
var
outerSaveTerm = _termState;
1733
_termState |=
TerminatorState
.IsEndOfRecordOrClassOrStructOrInterfaceSignature;
1735
var
saveTerm = _termState;
1736
_termState |=
TerminatorState
.IsPossibleAggregateClauseStartOrStop;
1793
var
saveTerm2 = _termState;
1794
_termState |=
TerminatorState
.IsPossibleMemberStartOrStop;
2058
Debug.Assert((_termState &
TerminatorState
.IsEndOfRecordOrClassOrStructOrInterfaceSignature) != 0);
2167
|| ((_termState &
TerminatorState
.IsEndOfRecordOrClassOrStructOrInterfaceSignature) != 0 && this.CurrentToken.Kind == SyntaxKind.SemicolonToken)
2487
var
saveTermState = _termState;
2657
var
saveTerm = _termState;
2658
_termState |=
TerminatorState
.IsPossibleStatementStartOrStop; // partial statements can abort if a new statement starts
2706
var
saveTerm = _termState;
2711
_termState |=
TerminatorState
.IsPossibleStatementStartOrStop;
2837
var
saveTerm = _termState;
2838
_termState |=
TerminatorState
.IsPossibleStatementStartOrStop; // partial statements can abort if a new statement starts
3059
var
saveTermState = _termState;
3307
var
saveTerm = _termState;
3308
_termState |=
TerminatorState
.IsEndOfMethodSignature;
3474
var
saveTerm = _termState;
3475
_termState |=
TerminatorState
.IsEndOfMethodSignature;
3529
var
saveTerm = _termState;
3530
_termState |=
TerminatorState
.IsEndOfReturnType;
4592
var
saveTerm = _termState;
4593
_termState |=
TerminatorState
.IsEndOfParameterList;
4990
var
saveTerm = _termState;
4991
_termState |=
TerminatorState
.IsEndOfFieldDeclaration;
5298
TerminatorState
saveTerm = _termState;
5358
_termState |=
TerminatorState
.IsPossibleEndOfVariableDeclaration;
5366
_termState |=
TerminatorState
.IsPossibleEndOfVariableDeclaration;
5499
var
saveTerm = _termState;
5500
_termState |=
TerminatorState
.IsEndOfMethodSignature;
5782
var
saveTerm = _termState;
5783
_termState |=
TerminatorState
.IsEndOfTypeParameterList;
5842
var
saveTerm = _termState;
5843
_termState =
TerminatorState
.IsEndOfTypeArgumentList;
6366
var
saveTerm = _termState;
6367
_termState =
TerminatorState
.IsEndOfTypeArgumentList;
6576
var
saveTerm = _termState;
6577
_termState |=
TerminatorState
.IsEndOfNameInExplicitInterface;
7096
TerminatorState
saveTerm;
7120
_termState |=
TerminatorState
.IsEndOfFunctionPointerCallingConvention;
7159
_termState |= validStartingToken ?
TerminatorState
.IsEndOfFunctionPointerParameterList :
TerminatorState
.IsEndOfFunctionPointerParameterListErrored;
7715
var
saveTerm = _termState;
7716
_termState |= (lessThanToken.IsMissing ?
TerminatorState
.IsEndOfFunctionPointerParameterListErrored :
TerminatorState
.IsEndOfFunctionPointerParameterList);
7803
var
saveTerm = _termState;
7804
_termState |=
TerminatorState
.IsEndOfFunctionPointerCallingConvention;
8415
var
saveTerm = _termState;
8416
_termState |=
TerminatorState
.IsEndOfFieldDeclaration;
8427
var
saveTerm = _termState;
8428
_termState |=
TerminatorState
.IsEndOfMethodSignature;
8749
var
saveTerm = _termState;
8750
_termState |=
TerminatorState
.IsPossibleStatementStartOrStop; // partial statements can abort if a new statement starts
8753
_termState |=
TerminatorState
.IsSwitchSectionStart;
8857
var
saveTerm = _termState;
8858
_termState |=
TerminatorState
.IsEndOfFixedStatement;
8955
var
saveTerm = _termState;
8956
_termState |=
TerminatorState
.IsEndOfTryBlock;
9017
var
saveTerm = _termState;
9023
_termState |=
TerminatorState
.IsEndOfCatchClause;
9053
_termState |=
TerminatorState
.IsEndOfFilterClause;
9062
_termState |=
TerminatorState
.IsEndOfCatchBlock;
9118
var
saveTerm = _termState;
9119
_termState |=
TerminatorState
.IsEndOfDoWhileExpression;
9176
var
saveTerm = _termState;
9177
_termState |=
TerminatorState
.IsEndOfForStatementArgument;
10291
var
saveTerm = _termState;
10292
_termState |=
TerminatorState
.IsEndOfDeclarationClause;
11938
var
saveTerm = _termState;
11939
_termState |=
TerminatorState
.IsEndOfArgumentList;
13383
var
saveTerm = _termState;
13384
_termState |=
TerminatorState
.IsEndOfParameterList;
14097
internal readonly
TerminatorState
TerminatorState;
14104
TerminatorState
terminatorState,
Parser\LanguageParser_Patterns.cs (6)
436
var
savedState = _termState;
437
_termState |=
TerminatorState
.IsExpressionOrPatternInCaseLabelOfSwitchStatement;
550
if (@this._termState.HasFlag(
TerminatorState
.IsExpressionOrPatternInCaseLabelOfSwitchStatement) && @this.CurrentToken.Kind is SyntaxKind.ColonToken)
559
if (@this._termState.HasFlag(
TerminatorState
.IsPatternInSwitchExpressionArm) && @this.CurrentToken.Kind is SyntaxKind.EqualsGreaterThanToken or SyntaxKind.ColonToken)
594
var
savedState = _termState;
595
_termState |=
TerminatorState
.IsPatternInSwitchExpressionArm;