233 references to TokenID
System.Workflow.Activities (233)
Rules\Parser\Intellisense.cs (31)
18
tokens.Add(new Token(
TokenID
.EndOfInput, 0, null));
47
if (token.TokenID ==
TokenID
.EndOfInput)
52
if (token.TokenID ==
TokenID
.Identifier && ((string)token.Value).Length == 1 && PrevToken().TokenID !=
TokenID
.Dot)
57
else if (token.TokenID ==
TokenID
.Dot)
62
else if (token.TokenID ==
TokenID
.LParen)
65
if (PrevToken().TokenID ==
TokenID
.Identifier)
67
if (PrevToken().TokenID ==
TokenID
.Dot)
83
if (CurrentToken.TokenID ==
TokenID
.New)
96
postfixTokens.Add(new Token(
TokenID
.EndOfInput, 0, null));
103
while (CurrentToken.TokenID ==
TokenID
.Dot)
108
case
TokenID
.Identifier:
109
case
TokenID
.TypeName:
113
case
TokenID
.This:
118
case
TokenID
.RParen:
121
if (!BackParseMatchingDelimiter(
TokenID
.LParen))
124
if (CurrentToken.TokenID ==
TokenID
.Identifier)
137
case
TokenID
.RBracket:
141
if (!BackParseMatchingDelimiter(
TokenID
.LBracket))
143
} while (CurrentToken.TokenID ==
TokenID
.RBracket);
146
if (CurrentToken.TokenID ==
TokenID
.Identifier)
151
else if (CurrentToken.TokenID ==
TokenID
.RParen)
155
if (!BackParseMatchingDelimiter(
TokenID
.LParen))
158
if (CurrentToken.TokenID ==
TokenID
.Identifier)
178
case
TokenID
.Greater:
179
if (!BackParseMatchingDelimiter(
TokenID
.Less))
182
if (CurrentToken.TokenID ==
TokenID
.Identifier)
202
if (CurrentToken.TokenID ==
TokenID
.New)
210
private bool BackParseMatchingDelimiter(
TokenID
openDelimiter)
212
TokenID
closeDelimiter = CurrentToken.TokenID;
216
while (token.TokenID !=
TokenID
.EndOfInput)
Rules\Parser\Parser.cs (110)
518
private
TokenID
token;
521
internal BinaryOperationDescriptor(
TokenID
token, CodeBinaryOperatorType codeDomOperator)
527
internal
TokenID
Token { get { return token; } }
540
internal NotEqualOperationDescriptor(
TokenID
token)
572
internal BinaryOperationDescriptor FindOperation(
TokenID
token)
585
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.Or, CodeBinaryOperatorType.BooleanOr)),
586
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.And, CodeBinaryOperatorType.BooleanAnd)),
588
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.BitOr, CodeBinaryOperatorType.BitwiseOr)),
590
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.BitAnd, CodeBinaryOperatorType.BitwiseAnd)),
592
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.Equal, CodeBinaryOperatorType.ValueEquality),
593
new BinaryOperationDescriptor(
TokenID
.Assign, CodeBinaryOperatorType.ValueEquality),
594
new NotEqualOperationDescriptor(
TokenID
.NotEqual)),
596
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.Less, CodeBinaryOperatorType.LessThan),
597
new BinaryOperationDescriptor(
TokenID
.LessEqual, CodeBinaryOperatorType.LessThanOrEqual),
598
new BinaryOperationDescriptor(
TokenID
.Greater, CodeBinaryOperatorType.GreaterThan),
599
new BinaryOperationDescriptor(
TokenID
.GreaterEqual, CodeBinaryOperatorType.GreaterThanOrEqual)),
601
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.Plus, CodeBinaryOperatorType.Add),
602
new BinaryOperationDescriptor(
TokenID
.Minus, CodeBinaryOperatorType.Subtract)),
604
new BinaryPrecedenceDescriptor(new BinaryOperationDescriptor(
TokenID
.Multiply, CodeBinaryOperatorType.Multiply),
605
new BinaryOperationDescriptor(
TokenID
.Divide, CodeBinaryOperatorType.Divide),
606
new BinaryOperationDescriptor(
TokenID
.Modulus, CodeBinaryOperatorType.Modulus))
944
if (parserContext.NumTokens == 2 && token.TokenID ==
TokenID
.Identifier)
947
System.Diagnostics.Debug.Assert(parserContext.NextToken().TokenID ==
TokenID
.EndOfInput);
1023
if (parserContext.CurrentToken.TokenID ==
TokenID
.EndOfInput)
1028
if (parserContext.CurrentToken.TokenID !=
TokenID
.EndOfInput)
1052
if (parserContext.CurrentToken.TokenID !=
TokenID
.EndOfInput)
1076
while (parserContext.CurrentToken.TokenID !=
TokenID
.EndOfInput)
1086
while (parserContext.CurrentToken.TokenID ==
TokenID
.Semicolon)
1104
if (statementToken.TokenID ==
TokenID
.Halt)
1111
else if (statementToken.TokenID ==
TokenID
.Update)
1117
if (parserContext.CurrentToken.TokenID !=
TokenID
.LParen)
1128
if (updateArgToken.TokenID ==
TokenID
.StringLiteral)
1155
if (parserContext.CurrentToken.TokenID !=
TokenID
.RParen)
1173
parserContext.CurrentToken.TokenID ==
TokenID
.LParen &&
1226
if (token.TokenID ==
TokenID
.Assign)
1303
if (currentToken.TokenID ==
TokenID
.Not)
1315
else if (currentToken.TokenID ==
TokenID
.Minus)
1327
else if (currentToken.TokenID ==
TokenID
.LParen)
1338
if (type == null || parserContext.CurrentToken.TokenID !=
TokenID
.RParen)
1354
if (parserContext.CurrentToken.TokenID !=
TokenID
.RParen)
1407
if (parserContext.CurrentToken.TokenID ==
TokenID
.Dot)
1411
else if (parserContext.CurrentToken.TokenID ==
TokenID
.LBracket)
1423
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.LBracket);
1464
while (parserContext.CurrentToken.TokenID ==
TokenID
.Comma)
1472
if (parserContext.CurrentToken.TokenID !=
TokenID
.RBracket)
1494
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.Dot);
1497
if (token.TokenID !=
TokenID
.Identifier)
1499
if (parserContext.provideIntellisense && token.TokenID ==
TokenID
.EndOfInput)
1515
if (parserContext.NextToken().TokenID ==
TokenID
.LParen)
1529
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.LParen);
1536
if (parserContext.CurrentToken.TokenID ==
TokenID
.EndOfInput && parserContext.provideIntellisense)
1556
if (parserContext.CurrentToken.TokenID !=
TokenID
.RParen)
1560
while (parserContext.CurrentToken.TokenID ==
TokenID
.Comma)
1568
if (parserContext.CurrentToken.TokenID !=
TokenID
.RParen)
1666
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.LParen);
1674
if (parserContext.CurrentToken.TokenID ==
TokenID
.EndOfInput && parserContext.provideIntellisense)
1723
case
TokenID
.In:
1727
case
TokenID
.Out:
1732
case
TokenID
.Ref:
1774
case
TokenID
.LParen:
1782
if (token.TokenID !=
TokenID
.RParen)
1788
case
TokenID
.Identifier:
1792
case
TokenID
.This:
1800
case
TokenID
.TypeName:
1812
case
TokenID
.New:
1817
case
TokenID
.IntegerLiteral:
1818
case
TokenID
.FloatLiteral:
1819
case
TokenID
.DecimalLiteral:
1820
case
TokenID
.CharacterLiteral:
1821
case
TokenID
.StringLiteral:
1822
case
TokenID
.True:
1823
case
TokenID
.False:
1824
case
TokenID
.Null:
1832
case
TokenID
.EndOfInput:
1854
if (parserContext.provideIntellisense && parserContext.CurrentToken.TokenID ==
TokenID
.EndOfInput)
1869
if (parserContext.CurrentToken.TokenID !=
TokenID
.LParen)
1912
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.LParen);
1918
if (parserContext.CurrentToken.TokenID ==
TokenID
.EndOfInput && parserContext.provideIntellisense)
1969
if (parserContext.CurrentToken.TokenID !=
TokenID
.LCurlyBrace)
1975
if (parserContext.CurrentToken.TokenID !=
TokenID
.RCurlyBrace)
1978
while (parserContext.CurrentToken.TokenID ==
TokenID
.Comma)
1984
if (parserContext.CurrentToken.TokenID !=
TokenID
.RCurlyBrace)
2045
if (parserContext.CurrentToken.TokenID ==
TokenID
.LParen)
2066
if (token.TokenID !=
TokenID
.Dot)
2070
if (token.TokenID !=
TokenID
.Identifier)
2072
if (parserContext.provideIntellisense && token.TokenID ==
TokenID
.EndOfInput)
2105
if (typeSym.GenericArgCount > 0 && token.TokenID !=
TokenID
.Less)
2114
if (token.TokenID ==
TokenID
.Less)
2138
if (token.TokenID ==
TokenID
.Dot)
2158
if (token.TokenID ==
TokenID
.Less)
2184
if (parserContext.CurrentToken.TokenID ==
TokenID
.Dot)
2198
if (parserContext.CurrentToken.TokenID ==
TokenID
.LParen)
2228
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.Dot);
2232
while (parserContext.CurrentToken.TokenID ==
TokenID
.Dot)
2239
if (token.TokenID !=
TokenID
.Identifier)
2241
if (parserContext.provideIntellisense && token.TokenID ==
TokenID
.EndOfInput)
2258
if (parserContext.NextToken().TokenID ==
TokenID
.Less)
2315
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.Less);
2333
System.Diagnostics.Debug.Assert(parserContext.CurrentToken.TokenID ==
TokenID
.Less);
2348
} while (parserContext.CurrentToken.TokenID ==
TokenID
.Comma);
2350
if (parserContext.CurrentToken.TokenID !=
TokenID
.Greater)
2374
if (currentToken.TokenID ==
TokenID
.TypeName)
2379
else if (currentToken.TokenID ==
TokenID
.Identifier)
2411
if ((type != null) && (parserContext.CurrentToken.TokenID ==
TokenID
.LBracket))
2415
if (next.TokenID !=
TokenID
.RBracket)
2420
if (parserContext.CurrentToken.TokenID !=
TokenID
.RBracket)
2448
while (parserContext.CurrentToken.TokenID ==
TokenID
.LBracket)
2451
while (parserContext.NextToken().TokenID ==
TokenID
.Comma)
2454
if (parserContext.CurrentToken.TokenID ==
TokenID
.RBracket)
2792
if (parserContext.CurrentToken.TokenID ==
TokenID
.Assign && !assignIsEquality)
Rules\Parser\Scanner.cs (90)
39
internal
TokenID
Token;
42
internal KeywordInfo(
TokenID
token, object tokenValue)
48
internal KeywordInfo(
TokenID
token)
58
map.Add("mod", new KeywordInfo(
TokenID
.Modulus));
59
map.Add("and", new KeywordInfo(
TokenID
.And));
60
map.Add("or", new KeywordInfo(
TokenID
.Or));
61
map.Add("not", new KeywordInfo(
TokenID
.Not));
62
map.Add("true", new KeywordInfo(
TokenID
.True, true));
63
map.Add("false", new KeywordInfo(
TokenID
.False, false));
64
map.Add("null", new KeywordInfo(
TokenID
.Null, null));
65
map.Add("nothing", new KeywordInfo(
TokenID
.Null, null));
66
map.Add("this", new KeywordInfo(
TokenID
.This));
67
map.Add("me", new KeywordInfo(
TokenID
.This));
68
map.Add("in", new KeywordInfo(
TokenID
.In));
69
map.Add("out", new KeywordInfo(
TokenID
.Out));
70
map.Add("ref", new KeywordInfo(
TokenID
.Ref));
71
map.Add("halt", new KeywordInfo(
TokenID
.Halt));
72
map.Add("update", new KeywordInfo(
TokenID
.Update));
73
map.Add("new", new KeywordInfo(
TokenID
.New));
74
map.Add("char", new KeywordInfo(
TokenID
.TypeName, typeof(char)));
75
map.Add("byte", new KeywordInfo(
TokenID
.TypeName, typeof(byte)));
76
map.Add("sbyte", new KeywordInfo(
TokenID
.TypeName, typeof(sbyte)));
77
map.Add("short", new KeywordInfo(
TokenID
.TypeName, typeof(short)));
78
map.Add("ushort", new KeywordInfo(
TokenID
.TypeName, typeof(ushort)));
79
map.Add("int", new KeywordInfo(
TokenID
.TypeName, typeof(int)));
80
map.Add("uint", new KeywordInfo(
TokenID
.TypeName, typeof(uint)));
81
map.Add("long", new KeywordInfo(
TokenID
.TypeName, typeof(long)));
82
map.Add("ulong", new KeywordInfo(
TokenID
.TypeName, typeof(ulong)));
83
map.Add("float", new KeywordInfo(
TokenID
.TypeName, typeof(float)));
84
map.Add("double", new KeywordInfo(
TokenID
.TypeName, typeof(double)));
85
map.Add("decimal", new KeywordInfo(
TokenID
.TypeName, typeof(decimal)));
86
map.Add("bool", new KeywordInfo(
TokenID
.TypeName, typeof(bool)));
87
map.Add("string", new KeywordInfo(
TokenID
.TypeName, typeof(string)));
88
map.Add("object", new KeywordInfo(
TokenID
.TypeName, typeof(object)));
119
private
TokenID
currentToken =
TokenID
.Unknown;
136
} while (token.TokenID !=
TokenID
.EndOfInput);
153
token = new Token(
TokenID
.Illegal, 0, null);
156
} while (token != null && token.TokenID !=
TokenID
.EndOfInput);
190
TokenID
tokenID =
TokenID
.Unknown;
196
return new Token(
TokenID
.EndOfInput, currentPosition, null);
217
tokenID =
TokenID
.Plus;
221
tokenID =
TokenID
.Minus;
225
tokenID =
TokenID
.Multiply;
229
tokenID =
TokenID
.Divide;
233
tokenID =
TokenID
.Modulus;
237
tokenID =
TokenID
.BitAnd;
241
tokenID =
TokenID
.And;
245
tokenID =
TokenID
.BitOr;
249
tokenID =
TokenID
.Or;
253
tokenID =
TokenID
.Assign;
258
tokenID =
TokenID
.Equal;
262
tokenID =
TokenID
.Not;
266
tokenID =
TokenID
.NotEqual;
270
tokenID =
TokenID
.Less;
275
tokenID =
TokenID
.LessEqual;
280
tokenID =
TokenID
.NotEqual;
284
tokenID =
TokenID
.Greater;
288
tokenID =
TokenID
.GreaterEqual;
292
tokenID =
TokenID
.LParen;
296
tokenID =
TokenID
.RParen;
300
tokenID =
TokenID
.Dot;
307
tokenID =
TokenID
.Comma;
311
tokenID =
TokenID
.Semicolon;
315
tokenID =
TokenID
.LBracket;
319
tokenID =
TokenID
.RBracket;
323
tokenID =
TokenID
.LCurlyBrace;
327
tokenID =
TokenID
.RCurlyBrace;
364
private
TokenID
ScanStringLiteral()
385
return
TokenID
.StringLiteral;
389
private
TokenID
ScanVerbatimStringLiteral()
424
return
TokenID
.StringLiteral;
506
private
TokenID
ScanCharacterLiteral()
516
return
TokenID
.CharacterLiteral;
519
private
TokenID
ScanNumber()
538
private
TokenID
ScanDecimal()
591
TokenID
token;
595
token =
TokenID
.FloatLiteral;
608
token =
TokenID
.FloatLiteral;
621
token =
TokenID
.DecimalLiteral;
634
token =
TokenID
.IntegerLiteral;
812
private
TokenID
ScanHexNumber()
844
TokenID
token =
TokenID
.IntegerLiteral;
899
private
TokenID
ScanKeywordOrIdentifier()
908
TokenID
token =
TokenID
.Unknown;
910
if (hasLettersOnly && currentToken !=
TokenID
.Dot)
923
token =
TokenID
.Identifier;
Rules\Parser\Token.cs (2)
64
internal
TokenID
TokenID;
68
internal Token(
TokenID
tokenID, int position, object value)