diff --git a/src/Libraries/NRefactory/Project/NRefactory.csproj b/src/Libraries/NRefactory/Project/NRefactory.csproj
index 35e2830af6..4bc62b2b43 100644
--- a/src/Libraries/NRefactory/Project/NRefactory.csproj
+++ b/src/Libraries/NRefactory/Project/NRefactory.csproj
@@ -53,9 +53,13 @@
3.5
+
+
+ ExpressionFinder.atg
+
@@ -84,9 +88,6 @@
-
- ExpressionFinder.atg
-
@@ -157,9 +158,7 @@
-
- CocoParserGenerator
-
+
@@ -167,7 +166,6 @@
Never
- CocoParserGenerator
ICSharpCode.NRefactory.Parser.VB
diff --git a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/KeywordList.txt b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/KeywordList.txt
index 346ad5bd2f..e003c6efc5 100644
--- a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/KeywordList.txt
+++ b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/KeywordList.txt
@@ -18,7 +18,14 @@ LiteralInteger
LiteralDouble
LiteralSingle
LiteralDecimal
-LiteralDate
+LiteralDate
+# XML_TERMINALS
+XmlOpenTag
+XmlCloseTag
+XmlStartInlineVB
+XmlEndInlineVB
+XmlCloseTagEmptyElement
+XmlOpenEndTag
# SPECIAL_CHARACTERS
Assign = "="
@@ -156,6 +163,7 @@ ConcatStringAssign = "&="
"IsNot"
# Note: IsTrue and IsFalse are 'NOT' keywords they're only valid in Operator declarations (like get/set/value are no C# 'keywords')
"Join"
+"Key"
"Let"
"Lib"
"Like"
diff --git a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Keywords.cs b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Keywords.cs
index 0a9ff48978..7d0000e401 100644
--- a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Keywords.cs
+++ b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Keywords.cs
@@ -97,6 +97,7 @@ namespace ICSharpCode.NRefactory.Parser.VB
"IS",
"ISNOT",
"JOIN",
+ "KEY",
"LET",
"LIB",
"LIKE",
diff --git a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Lexer.cs b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Lexer.cs
index 9854579476..34a63739da 100644
--- a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Lexer.cs
+++ b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Lexer.cs
@@ -9,6 +9,8 @@ using System;
using System.Globalization;
using System.IO;
using System.Text;
+using System.Xml;
+using ICSharpCode.NRefactory.Parser.VBNet.Experimental;
namespace ICSharpCode.NRefactory.Parser.VB
{
@@ -17,8 +19,11 @@ namespace ICSharpCode.NRefactory.Parser.VB
bool lineEnd = true;
bool isAtLineBegin = false; // TODO: handle line begin, if neccessarry
+ ExpressionFinder ef;
+
public Lexer(TextReader reader) : base(reader)
{
+ ef = new ExpressionFinder();
}
public override Token NextToken()
@@ -26,6 +31,7 @@ namespace ICSharpCode.NRefactory.Parser.VB
if (curToken == null) { // first call of NextToken()
curToken = Next();
specialTracker.InformToken(curToken.kind);
+ ef.InformToken(curToken);
//Console.WriteLine("Tok:" + Tokens.GetTokenString(curToken.kind) + " --- " + curToken.val);
return curToken;
}
@@ -35,6 +41,7 @@ namespace ICSharpCode.NRefactory.Parser.VB
if (curToken.next == null) {
curToken.next = Next();
specialTracker.InformToken(curToken.next.kind);
+ ef.InformToken(curToken);
}
curToken = curToken.next;
@@ -42,14 +49,18 @@ namespace ICSharpCode.NRefactory.Parser.VB
if (curToken.kind == Tokens.EOF && !(lastToken.kind == Tokens.EOL)) { // be sure that before EOF there is an EOL token
curToken = new Token(Tokens.EOL, curToken.col, curToken.line, string.Empty);
specialTracker.InformToken(curToken.kind);
+ ef.InformToken(curToken);
curToken.next = new Token(Tokens.EOF, curToken.col, curToken.line, string.Empty);
specialTracker.InformToken(curToken.next.kind);
+ ef.InformToken(curToken);
}
//Console.WriteLine("Tok:" + Tokens.GetTokenString(curToken.kind) + " --- " + curToken.val);
return curToken;
}
bool misreadExclamationMarkAsTypeCharacter;
+ bool inXmlMode, expectXmlIdentifier, inXmlTag, inXmlCloseTag;
+ int level = 0;
protected override Token Next()
{
@@ -64,170 +75,229 @@ namespace ICSharpCode.NRefactory.Parser.VB
if (nextChar == -1)
return new Token(Tokens.EOF, Col, Line, string.Empty);
char ch = (char)nextChar;
- if (Char.IsWhiteSpace(ch)) {
- if (HandleLineEnd(ch)) {
- if (lineEnd) {
- // second line end before getting to a token
- // -> here was a blank line
- specialTracker.AddEndOfLine(startLocation);
- } else {
- lineEnd = true;
- return new Token(Tokens.EOL, startLocation, new Location(Col, Line), null, null, LiteralFormat.None);
- }
- }
- continue;
+ if (inXmlMode && level <= 0) {
+// int peek;
+// while ((peek = ReaderPeek()) != -1 && XmlConvert.IsWhitespaceChar((char)peek)) ;
+//
+// inXmlMode = ReaderPeek() == '<' &&
+// ReaderPeek() == '!' &&
+// ReaderPeek() == '-' &&
+// ReaderPeek() == '-';
+ inXmlMode = false;
}
- if (ch == '_') {
- if (ReaderPeek() == -1) {
- errors.Error(Line, Col, String.Format("No EOF expected after _"));
- return new Token(Tokens.EOF, Col, Line, string.Empty);
- }
- if (!Char.IsWhiteSpace((char)ReaderPeek())) {
- int x = Col - 1;
- int y = Line;
- string s = ReadIdent('_');
- lineEnd = false;
- return new Token(Tokens.Identifier, x, y, s);
+ if (inXmlMode) {
+ switch (ch) {
+ case '<':
+ if (ReaderPeek() == '/') {
+ inXmlCloseTag = true;
+ return new Token(Tokens.XmlOpenEndTag, Col - 1, Line);
+ }
+ if (ReaderPeek() == '%') {
+ // TODO : suspend xml mode tracking
+ return new Token(Tokens.XmlStartInlineVB, Col - 1, Line);
+ }
+
+ return new Token(Tokens.XmlOpenTag, Col - 1, Line);
+ case '/':
+ if (ReaderPeek() == '>')
+ return new Token(Tokens.XmlCloseTagEmptyElement, Col - 1, Line);
+ break;
+ case '%':
+ if (ReaderPeek() == '>') {
+ // TODO : resume xml mode tracking
+ return new Token(Tokens.XmlEndInlineVB, Col - 1, Line);
+ }
+ break;
+ case '>':
+ if (inXmlCloseTag)
+ level--;
+ return new Token(Tokens.XmlCloseTag, Col - 1, Line);
+ case '=':
+ return new Token(Tokens.Equals, Col - 1, Line);
+ case '\'':
+ case '"':
+ int x = Col - 1;
+ int y = Line;
+ string s = ReadXmlString(ch);
+ return new Token(Tokens.LiteralString, Col - 1, Line, '"' + s + '"', s, LiteralFormat.StringLiteral);
+ default:
+ // TODO : can be either identifier or xml content
+ return new Token(Tokens.Identifier, Col - 1, Line, ReadXmlIdent(ch));
}
- ch = (char)ReaderRead();
-
- bool oldLineEnd = lineEnd;
- lineEnd = false;
- while (Char.IsWhiteSpace(ch)) {
+ } else {
+ if (Char.IsWhiteSpace(ch)) {
if (HandleLineEnd(ch)) {
- lineEnd = true;
- break;
+ if (lineEnd) {
+ // second line end before getting to a token
+ // -> here was a blank line
+ specialTracker.AddEndOfLine(startLocation);
+ } else {
+ lineEnd = true;
+ return new Token(Tokens.EOL, startLocation, new Location(Col, Line), null, null, LiteralFormat.None);
+ }
}
- if (ReaderPeek() != -1) {
- ch = (char)ReaderRead();
- } else {
+ continue;
+ }
+ if (ch == '_') {
+ if (ReaderPeek() == -1) {
errors.Error(Line, Col, String.Format("No EOF expected after _"));
return new Token(Tokens.EOF, Col, Line, string.Empty);
}
+ if (!Char.IsWhiteSpace((char)ReaderPeek())) {
+ int x = Col - 1;
+ int y = Line;
+ string s = ReadIdent('_');
+ lineEnd = false;
+ return new Token(Tokens.Identifier, x, y, s);
+ }
+ ch = (char)ReaderRead();
+
+ bool oldLineEnd = lineEnd;
+ lineEnd = false;
+ while (Char.IsWhiteSpace(ch)) {
+ if (HandleLineEnd(ch)) {
+ lineEnd = true;
+ break;
+ }
+ if (ReaderPeek() != -1) {
+ ch = (char)ReaderRead();
+ } else {
+ errors.Error(Line, Col, String.Format("No EOF expected after _"));
+ return new Token(Tokens.EOF, Col, Line, string.Empty);
+ }
+ }
+ if (!lineEnd) {
+ errors.Error(Line, Col, String.Format("Return expected"));
+ }
+ lineEnd = oldLineEnd;
+ continue;
}
- if (!lineEnd) {
- errors.Error(Line, Col, String.Format("Return expected"));
- }
- lineEnd = oldLineEnd;
- continue;
- }
-
- if (ch == '#') {
- while (Char.IsWhiteSpace((char)ReaderPeek())) {
- ReaderRead();
+
+ if (ch == '#') {
+ while (Char.IsWhiteSpace((char)ReaderPeek())) {
+ ReaderRead();
+ }
+ if (Char.IsDigit((char)ReaderPeek())) {
+ int x = Col - 1;
+ int y = Line;
+ string s = ReadDate();
+ DateTime time = new DateTime(1, 1, 1, 0, 0, 0);
+ try {
+ time = DateTime.Parse(s, System.Globalization.CultureInfo.InvariantCulture, DateTimeStyles.NoCurrentDateDefault);
+ } catch (Exception e) {
+ errors.Error(Line, Col, String.Format("Invalid date time {0}", e));
+ }
+ return new Token(Tokens.LiteralDate, x, y, s, time, LiteralFormat.DateTimeLiteral);
+ } else {
+ ReadPreprocessorDirective();
+ continue;
+ }
}
- if (Char.IsDigit((char)ReaderPeek())) {
+
+ if (ch == '[') { // Identifier
+ lineEnd = false;
+ if (ReaderPeek() == -1) {
+ errors.Error(Line, Col, String.Format("Identifier expected"));
+ }
+ ch = (char)ReaderRead();
+ if (ch == ']' || Char.IsWhiteSpace(ch)) {
+ errors.Error(Line, Col, String.Format("Identifier expected"));
+ }
int x = Col - 1;
int y = Line;
- string s = ReadDate();
- DateTime time = new DateTime(1, 1, 1, 0, 0, 0);
- try {
- time = DateTime.Parse(s, System.Globalization.CultureInfo.InvariantCulture, DateTimeStyles.NoCurrentDateDefault);
- } catch (Exception e) {
- errors.Error(Line, Col, String.Format("Invalid date time {0}", e));
+ string s = ReadIdent(ch);
+ if (ReaderPeek() == -1) {
+ errors.Error(Line, Col, String.Format("']' expected"));
}
- return new Token(Tokens.LiteralDate, x, y, s, time, LiteralFormat.DateTimeLiteral);
- } else {
- ReadPreprocessorDirective();
- continue;
+ ch = (char)ReaderRead();
+ if (!(ch == ']')) {
+ errors.Error(Line, Col, String.Format("']' expected"));
+ }
+ return new Token(Tokens.Identifier, x, y, s);
}
- }
-
- if (ch == '[') { // Identifier
- lineEnd = false;
- if (ReaderPeek() == -1) {
- errors.Error(Line, Col, String.Format("Identifier expected"));
+ if (Char.IsLetter(ch)) {
+ int x = Col - 1;
+ int y = Line;
+ char typeCharacter;
+ string s = ReadIdent(ch, out typeCharacter);
+ if (typeCharacter == '\0') {
+ int keyWordToken = Keywords.GetToken(s);
+ if (keyWordToken >= 0) {
+ // handle 'REM' comments
+ if (keyWordToken == Tokens.Rem) {
+ ReadComment();
+ if (!lineEnd) {
+ lineEnd = true;
+ return new Token(Tokens.EOL, Col, Line, "\n");
+ }
+ continue;
+ }
+
+ lineEnd = false;
+ return new Token(keyWordToken, x, y, s);
+ }
+ }
+
+ lineEnd = false;
+ return new Token(Tokens.Identifier, x, y, s);
+
}
- ch = (char)ReaderRead();
- if (ch == ']' || Char.IsWhiteSpace(ch)) {
- errors.Error(Line, Col, String.Format("Identifier expected"));
+ if (Char.IsDigit(ch)) {
+ lineEnd = false;
+ return ReadDigit(ch, Col - 1);
}
- int x = Col - 1;
- int y = Line;
- string s = ReadIdent(ch);
- if (ReaderPeek() == -1) {
- errors.Error(Line, Col, String.Format("']' expected"));
+ if (ch == '&') {
+ lineEnd = false;
+ if (ReaderPeek() == -1) {
+ return ReadOperator('&');
+ }
+ ch = (char)ReaderPeek();
+ if (Char.ToUpper(ch, CultureInfo.InvariantCulture) == 'H' || Char.ToUpper(ch, CultureInfo.InvariantCulture) == 'O') {
+ return ReadDigit('&', Col - 1);
+ }
+ return ReadOperator('&');
}
- ch = (char)ReaderRead();
- if (!(ch == ']')) {
- errors.Error(Line, Col, String.Format("']' expected"));
+ if (ch == '\'' || ch == '\u2018' || ch == '\u2019') {
+ int x = Col - 1;
+ int y = Line;
+ ReadComment();
+ if (!lineEnd) {
+ lineEnd = true;
+ return new Token(Tokens.EOL, x, y, "\n");
+ }
+ continue;
}
- return new Token(Tokens.Identifier, x, y, s);
- }
- if (Char.IsLetter(ch)) {
- int x = Col - 1;
- int y = Line;
- char typeCharacter;
- string s = ReadIdent(ch, out typeCharacter);
- if (typeCharacter == '\0') {
- int keyWordToken = Keywords.GetToken(s);
- if (keyWordToken >= 0) {
- // handle 'REM' comments
- if (keyWordToken == Tokens.Rem) {
- ReadComment();
- if (!lineEnd) {
- lineEnd = true;
- return new Token(Tokens.EOL, Col, Line, "\n");
- }
- continue;
+ if (ch == '"') {
+ lineEnd = false;
+ int x = Col - 1;
+ int y = Line;
+ string s = ReadString();
+ if (ReaderPeek() != -1 && (ReaderPeek() == 'C' || ReaderPeek() == 'c')) {
+ ReaderRead();
+ if (s.Length != 1) {
+ errors.Error(Line, Col, String.Format("Chars can only have Length 1 "));
}
-
- lineEnd = false;
- return new Token(keyWordToken, x, y, s);
+ if (s.Length == 0) {
+ s = "\0";
+ }
+ return new Token(Tokens.LiteralCharacter, x, y, '"' + s + "\"C", s[0], LiteralFormat.CharLiteral);
}
+ return new Token(Tokens.LiteralString, x, y, '"' + s + '"', s, LiteralFormat.StringLiteral);
}
- lineEnd = false;
- return new Token(Tokens.Identifier, x, y, s);
-
- }
- if (Char.IsDigit(ch)) {
- lineEnd = false;
- return ReadDigit(ch, Col - 1);
- }
- if (ch == '&') {
- lineEnd = false;
- if (ReaderPeek() == -1) {
- return ReadOperator('&');
- }
- ch = (char)ReaderPeek();
- if (Char.ToUpper(ch, CultureInfo.InvariantCulture) == 'H' || Char.ToUpper(ch, CultureInfo.InvariantCulture) == 'O') {
- return ReadDigit('&', Col - 1);
- }
- return ReadOperator('&');
- }
- if (ch == '\'' || ch == '\u2018' || ch == '\u2019') {
- int x = Col - 1;
- int y = Line;
- ReadComment();
- if (!lineEnd) {
- lineEnd = true;
- return new Token(Tokens.EOL, x, y, "\n");
+ if (ch == '<' && ef.NextTokenIsPotentialStartOfXmlMode) {
+ inXmlMode = inXmlTag = true;
+ level = 1;
+ return new Token(Tokens.XmlOpenTag, Col - 1, Line);
}
- continue;
- }
- if (ch == '"') {
- lineEnd = false;
- int x = Col - 1;
- int y = Line;
- string s = ReadString();
- if (ReaderPeek() != -1 && (ReaderPeek() == 'C' || ReaderPeek() == 'c')) {
- ReaderRead();
- if (s.Length != 1) {
- errors.Error(Line, Col, String.Format("Chars can only have Length 1 "));
- }
- if (s.Length == 0) {
- s = "\0";
- }
- return new Token(Tokens.LiteralCharacter, x, y, '"' + s + "\"C", s[0], LiteralFormat.CharLiteral);
+ Token token = ReadOperator(ch);
+ if (token != null) {
+ lineEnd = false;
+ return token;
}
- return new Token(Tokens.LiteralString, x, y, '"' + s + '"', s, LiteralFormat.StringLiteral);
- }
- Token token = ReadOperator(ch);
- if (token != null) {
- lineEnd = false;
- return token;
}
+
+
errors.Error(Line, Col, String.Format("Unknown char({0}) which can't be read", ch));
}
}
@@ -267,6 +337,21 @@ namespace ICSharpCode.NRefactory.Parser.VB
return sb.ToString();
}
+ string ReadXmlIndent(char ch)
+ {
+ sb.Length = 0;
+ sb.Append(ch);
+
+ int peek;
+
+ while ((peek = ReaderPeek()) != -1 && (peek == ':' || XmlConvert.IsNCNameChar((char)peek))) {
+ ReaderRead();
+ sb.Append(ch);
+ }
+
+ return sb.ToString();
+ }
+
char PeekUpperChar()
{
return Char.ToUpper((char)ReaderPeek(), CultureInfo.InvariantCulture);
@@ -558,6 +643,32 @@ namespace ICSharpCode.NRefactory.Parser.VB
return sb.ToString();
}
+ string ReadXmlString(char terminator)
+ {
+ char ch = '\0';
+ sb.Length = 0;
+ int nextChar;
+ while ((nextChar = ReaderRead()) != -1) {
+ ch = (char)nextChar;
+ if (ch == terminator) {
+ if (ReaderPeek() != -1 && ReaderPeek() == terminator) {
+ sb.Append(terminator);
+ ReaderRead();
+ } else {
+ break;
+ }
+ } else if (ch == '\n') {
+ errors.Error(Line, Col, String.Format("No return allowed inside String literal"));
+ } else {
+ sb.Append(ch);
+ }
+ }
+ if (ch != terminator) {
+ errors.Error(Line, Col, String.Format("End of File reached before String terminated "));
+ }
+ return sb.ToString();
+ }
+
void ReadComment()
{
Location startPos = new Location(Col, Line);
diff --git a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Tokens.cs b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Tokens.cs
index f8aa16a1ed..469dfd0f9f 100644
--- a/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Tokens.cs
+++ b/src/Libraries/NRefactory/Project/Src/Lexer/VBNet/Tokens.cs
@@ -17,224 +17,231 @@ namespace ICSharpCode.NRefactory.Parser.VB
public const int LiteralSingle = 7;
public const int LiteralDecimal = 8;
public const int LiteralDate = 9;
+ public const int XmlOpenTag = 10;
+ public const int XmlCloseTag = 11;
+ public const int XmlStartInlineVB = 12;
+ public const int XmlEndInlineVB = 13;
+ public const int XmlCloseTagEmptyElement = 14;
+ public const int XmlOpenEndTag = 15;
// ----- special character -----
- public const int Assign = 10;
- public const int Colon = 11;
- public const int Comma = 12;
- public const int ConcatString = 13;
- public const int Div = 14;
- public const int DivInteger = 15;
- public const int Dot = 16;
- public const int ExclamationMark = 17;
- public const int Minus = 18;
- public const int Plus = 19;
- public const int Power = 20;
- public const int QuestionMark = 21;
- public const int Times = 22;
- public const int OpenCurlyBrace = 23;
- public const int CloseCurlyBrace = 24;
- public const int OpenParenthesis = 25;
- public const int CloseParenthesis = 26;
- public const int GreaterThan = 27;
- public const int LessThan = 28;
- public const int NotEqual = 29;
- public const int GreaterEqual = 30;
- public const int LessEqual = 31;
- public const int ShiftLeft = 32;
- public const int ShiftRight = 33;
- public const int PlusAssign = 34;
- public const int PowerAssign = 35;
- public const int MinusAssign = 36;
- public const int TimesAssign = 37;
- public const int DivAssign = 38;
- public const int DivIntegerAssign = 39;
- public const int ShiftLeftAssign = 40;
- public const int ShiftRightAssign = 41;
- public const int ConcatStringAssign = 42;
+ public const int Assign = 16;
+ public const int Colon = 17;
+ public const int Comma = 18;
+ public const int ConcatString = 19;
+ public const int Div = 20;
+ public const int DivInteger = 21;
+ public const int Dot = 22;
+ public const int ExclamationMark = 23;
+ public const int Minus = 24;
+ public const int Plus = 25;
+ public const int Power = 26;
+ public const int QuestionMark = 27;
+ public const int Times = 28;
+ public const int OpenCurlyBrace = 29;
+ public const int CloseCurlyBrace = 30;
+ public const int OpenParenthesis = 31;
+ public const int CloseParenthesis = 32;
+ public const int GreaterThan = 33;
+ public const int LessThan = 34;
+ public const int NotEqual = 35;
+ public const int GreaterEqual = 36;
+ public const int LessEqual = 37;
+ public const int ShiftLeft = 38;
+ public const int ShiftRight = 39;
+ public const int PlusAssign = 40;
+ public const int PowerAssign = 41;
+ public const int MinusAssign = 42;
+ public const int TimesAssign = 43;
+ public const int DivAssign = 44;
+ public const int DivIntegerAssign = 45;
+ public const int ShiftLeftAssign = 46;
+ public const int ShiftRightAssign = 47;
+ public const int ConcatStringAssign = 48;
// ----- keywords -----
- public const int AddHandler = 43;
- public const int AddressOf = 44;
- public const int Aggregate = 45;
- public const int Alias = 46;
- public const int And = 47;
- public const int AndAlso = 48;
- public const int Ansi = 49;
- public const int As = 50;
- public const int Ascending = 51;
- public const int Assembly = 52;
- public const int Auto = 53;
- public const int Binary = 54;
- public const int Boolean = 55;
- public const int ByRef = 56;
- public const int By = 57;
- public const int Byte = 58;
- public const int ByVal = 59;
- public const int Call = 60;
- public const int Case = 61;
- public const int Catch = 62;
- public const int CBool = 63;
- public const int CByte = 64;
- public const int CChar = 65;
- public const int CDate = 66;
- public const int CDbl = 67;
- public const int CDec = 68;
- public const int Char = 69;
- public const int CInt = 70;
- public const int Class = 71;
- public const int CLng = 72;
- public const int CObj = 73;
- public const int Compare = 74;
- public const int Const = 75;
- public const int Continue = 76;
- public const int CSByte = 77;
- public const int CShort = 78;
- public const int CSng = 79;
- public const int CStr = 80;
- public const int CType = 81;
- public const int CUInt = 82;
- public const int CULng = 83;
- public const int CUShort = 84;
- public const int Custom = 85;
- public const int Date = 86;
- public const int Decimal = 87;
- public const int Declare = 88;
- public const int Default = 89;
- public const int Delegate = 90;
- public const int Descending = 91;
- public const int Dim = 92;
- public const int DirectCast = 93;
- public const int Distinct = 94;
- public const int Do = 95;
- public const int Double = 96;
- public const int Each = 97;
- public const int Else = 98;
- public const int ElseIf = 99;
- public const int End = 100;
- public const int EndIf = 101;
- public const int Enum = 102;
- new public const int Equals = 103;
- public const int Erase = 104;
- public const int Error = 105;
- public const int Event = 106;
- public const int Exit = 107;
- public const int Explicit = 108;
- public const int False = 109;
- public const int Finally = 110;
- public const int For = 111;
- public const int Friend = 112;
- public const int From = 113;
- public const int Function = 114;
- public const int Get = 115;
- new public const int GetType = 116;
- public const int Global = 117;
- public const int GoSub = 118;
- public const int GoTo = 119;
- public const int Group = 120;
- public const int Handles = 121;
- public const int If = 122;
- public const int Implements = 123;
- public const int Imports = 124;
- public const int In = 125;
- public const int Infer = 126;
- public const int Inherits = 127;
- public const int Integer = 128;
- public const int Interface = 129;
- public const int Into = 130;
- public const int Is = 131;
- public const int IsNot = 132;
- public const int Join = 133;
- public const int Let = 134;
- public const int Lib = 135;
- public const int Like = 136;
- public const int Long = 137;
- public const int Loop = 138;
- public const int Me = 139;
- public const int Mod = 140;
- public const int Module = 141;
- public const int MustInherit = 142;
- public const int MustOverride = 143;
- public const int MyBase = 144;
- public const int MyClass = 145;
- public const int Namespace = 146;
- public const int Narrowing = 147;
- public const int New = 148;
- public const int Next = 149;
- public const int Not = 150;
- public const int Nothing = 151;
- public const int NotInheritable = 152;
- public const int NotOverridable = 153;
- public const int Object = 154;
- public const int Of = 155;
- public const int Off = 156;
- public const int On = 157;
- public const int Operator = 158;
- public const int Option = 159;
- public const int Optional = 160;
- public const int Or = 161;
- public const int Order = 162;
- public const int OrElse = 163;
- public const int Overloads = 164;
- public const int Overridable = 165;
- public const int Overrides = 166;
- public const int ParamArray = 167;
- public const int Partial = 168;
- public const int Preserve = 169;
- public const int Private = 170;
- public const int Property = 171;
- public const int Protected = 172;
- public const int Public = 173;
- public const int RaiseEvent = 174;
- public const int ReadOnly = 175;
- public const int ReDim = 176;
- public const int Rem = 177;
- public const int RemoveHandler = 178;
- public const int Resume = 179;
- public const int Return = 180;
- public const int SByte = 181;
- public const int Select = 182;
- public const int Set = 183;
- public const int Shadows = 184;
- public const int Shared = 185;
- public const int Short = 186;
- public const int Single = 187;
- public const int Skip = 188;
- public const int Static = 189;
- public const int Step = 190;
- public const int Stop = 191;
- public const int Strict = 192;
- public const int String = 193;
- public const int Structure = 194;
- public const int Sub = 195;
- public const int SyncLock = 196;
- public const int Take = 197;
- public const int Text = 198;
- public const int Then = 199;
- public const int Throw = 200;
- public const int To = 201;
- public const int True = 202;
- public const int Try = 203;
- public const int TryCast = 204;
- public const int TypeOf = 205;
- public const int UInteger = 206;
- public const int ULong = 207;
- public const int Unicode = 208;
- public const int Until = 209;
- public const int UShort = 210;
- public const int Using = 211;
- public const int Variant = 212;
- public const int Wend = 213;
- public const int When = 214;
- public const int Where = 215;
- public const int While = 216;
- public const int Widening = 217;
- public const int With = 218;
- public const int WithEvents = 219;
- public const int WriteOnly = 220;
- public const int Xor = 221;
+ public const int AddHandler = 49;
+ public const int AddressOf = 50;
+ public const int Aggregate = 51;
+ public const int Alias = 52;
+ public const int And = 53;
+ public const int AndAlso = 54;
+ public const int Ansi = 55;
+ public const int As = 56;
+ public const int Ascending = 57;
+ public const int Assembly = 58;
+ public const int Auto = 59;
+ public const int Binary = 60;
+ public const int Boolean = 61;
+ public const int ByRef = 62;
+ public const int By = 63;
+ public const int Byte = 64;
+ public const int ByVal = 65;
+ public const int Call = 66;
+ public const int Case = 67;
+ public const int Catch = 68;
+ public const int CBool = 69;
+ public const int CByte = 70;
+ public const int CChar = 71;
+ public const int CDate = 72;
+ public const int CDbl = 73;
+ public const int CDec = 74;
+ public const int Char = 75;
+ public const int CInt = 76;
+ public const int Class = 77;
+ public const int CLng = 78;
+ public const int CObj = 79;
+ public const int Compare = 80;
+ public const int Const = 81;
+ public const int Continue = 82;
+ public const int CSByte = 83;
+ public const int CShort = 84;
+ public const int CSng = 85;
+ public const int CStr = 86;
+ public const int CType = 87;
+ public const int CUInt = 88;
+ public const int CULng = 89;
+ public const int CUShort = 90;
+ public const int Custom = 91;
+ public const int Date = 92;
+ public const int Decimal = 93;
+ public const int Declare = 94;
+ public const int Default = 95;
+ public const int Delegate = 96;
+ public const int Descending = 97;
+ public const int Dim = 98;
+ public const int DirectCast = 99;
+ public const int Distinct = 100;
+ public const int Do = 101;
+ public const int Double = 102;
+ public const int Each = 103;
+ public const int Else = 104;
+ public const int ElseIf = 105;
+ public const int End = 106;
+ public const int EndIf = 107;
+ public const int Enum = 108;
+ new public const int Equals = 109;
+ public const int Erase = 110;
+ public const int Error = 111;
+ public const int Event = 112;
+ public const int Exit = 113;
+ public const int Explicit = 114;
+ public const int False = 115;
+ public const int Finally = 116;
+ public const int For = 117;
+ public const int Friend = 118;
+ public const int From = 119;
+ public const int Function = 120;
+ public const int Get = 121;
+ new public const int GetType = 122;
+ public const int Global = 123;
+ public const int GoSub = 124;
+ public const int GoTo = 125;
+ public const int Group = 126;
+ public const int Handles = 127;
+ public const int If = 128;
+ public const int Implements = 129;
+ public const int Imports = 130;
+ public const int In = 131;
+ public const int Infer = 132;
+ public const int Inherits = 133;
+ public const int Integer = 134;
+ public const int Interface = 135;
+ public const int Into = 136;
+ public const int Is = 137;
+ public const int IsNot = 138;
+ public const int Join = 139;
+ public const int Key = 140;
+ public const int Let = 141;
+ public const int Lib = 142;
+ public const int Like = 143;
+ public const int Long = 144;
+ public const int Loop = 145;
+ public const int Me = 146;
+ public const int Mod = 147;
+ public const int Module = 148;
+ public const int MustInherit = 149;
+ public const int MustOverride = 150;
+ public const int MyBase = 151;
+ public const int MyClass = 152;
+ public const int Namespace = 153;
+ public const int Narrowing = 154;
+ public const int New = 155;
+ public const int Next = 156;
+ public const int Not = 157;
+ public const int Nothing = 158;
+ public const int NotInheritable = 159;
+ public const int NotOverridable = 160;
+ public const int Object = 161;
+ public const int Of = 162;
+ public const int Off = 163;
+ public const int On = 164;
+ public const int Operator = 165;
+ public const int Option = 166;
+ public const int Optional = 167;
+ public const int Or = 168;
+ public const int Order = 169;
+ public const int OrElse = 170;
+ public const int Overloads = 171;
+ public const int Overridable = 172;
+ public const int Overrides = 173;
+ public const int ParamArray = 174;
+ public const int Partial = 175;
+ public const int Preserve = 176;
+ public const int Private = 177;
+ public const int Property = 178;
+ public const int Protected = 179;
+ public const int Public = 180;
+ public const int RaiseEvent = 181;
+ public const int ReadOnly = 182;
+ public const int ReDim = 183;
+ public const int Rem = 184;
+ public const int RemoveHandler = 185;
+ public const int Resume = 186;
+ public const int Return = 187;
+ public const int SByte = 188;
+ public const int Select = 189;
+ public const int Set = 190;
+ public const int Shadows = 191;
+ public const int Shared = 192;
+ public const int Short = 193;
+ public const int Single = 194;
+ public const int Skip = 195;
+ public const int Static = 196;
+ public const int Step = 197;
+ public const int Stop = 198;
+ public const int Strict = 199;
+ public const int String = 200;
+ public const int Structure = 201;
+ public const int Sub = 202;
+ public const int SyncLock = 203;
+ public const int Take = 204;
+ public const int Text = 205;
+ public const int Then = 206;
+ public const int Throw = 207;
+ public const int To = 208;
+ public const int True = 209;
+ public const int Try = 210;
+ public const int TryCast = 211;
+ public const int TypeOf = 212;
+ public const int UInteger = 213;
+ public const int ULong = 214;
+ public const int Unicode = 215;
+ public const int Until = 216;
+ public const int UShort = 217;
+ public const int Using = 218;
+ public const int Variant = 219;
+ public const int Wend = 220;
+ public const int When = 221;
+ public const int Where = 222;
+ public const int While = 223;
+ public const int Widening = 224;
+ public const int With = 225;
+ public const int WithEvents = 226;
+ public const int WriteOnly = 227;
+ public const int Xor = 228;
- public const int MaxToken = 222;
+ public const int MaxToken = 229;
static BitArray NewSet(params int[] values)
{
BitArray bitArray = new BitArray(MaxToken);
@@ -261,6 +268,12 @@ namespace ICSharpCode.NRefactory.Parser.VB
"",
"",
"",
+ "",
+ "",
+ "",
+ "",
+ "",
+ "",
// ----- special character -----
"=",
":",
@@ -387,6 +400,7 @@ namespace ICSharpCode.NRefactory.Parser.VB
"Is",
"IsNot",
"Join",
+ "Key",
"Let",
"Lib",
"Like",
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/CSharp/Parser.cs b/src/Libraries/NRefactory/Project/Src/Parser/CSharp/Parser.cs
index 1547241cac..930a336d3d 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/CSharp/Parser.cs
+++ b/src/Libraries/NRefactory/Project/Src/Parser/CSharp/Parser.cs
@@ -1,3 +1,5 @@
+
+#line 1 "cs.ATG"
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
@@ -6,40 +8,44 @@ using ICSharpCode.NRefactory.Parser;
using ICSharpCode.NRefactory.Ast;
using ASTAttribute = ICSharpCode.NRefactory.Ast.Attribute;
using Types = ICSharpCode.NRefactory.Ast.ClassType;
-
-
-
+/*
+ Parser.frame file for NRefactory.
+ */
using System;
+using System.Reflection;
namespace ICSharpCode.NRefactory.Parser.CSharp {
+
partial class Parser : AbstractParser
{
- public const int _EOF = 0;
- public const int _ident = 1;
- public const int _Literal = 2;
- public const int maxT = 145; // 0) {
INode node;
if (aliasedType != null) {
@@ -82,30 +108,46 @@ partial class Parser : AbstractParser
node.EndLocation = t.EndLocation;
compilationUnit.AddChild(node);
}
-
+
}
void GlobalAttributeSection() {
Expect(18);
- Location startPos = t.Location;
+
+#line 213 "cs.ATG"
+ Location startPos = t.Location;
Identifier();
+
+#line 214 "cs.ATG"
if (t.val != "assembly" && t.val != "module") Error("global attribute target specifier (assembly or module) expected");
string attributeTarget = t.val;
List attributes = new List();
ASTAttribute attribute;
-
+
Expect(9);
- Attribute(out attribute);
- attributes.Add(attribute);
- while (NotFinalComma()) {
+ Attribute(
+#line 219 "cs.ATG"
+out attribute);
+
+#line 219 "cs.ATG"
+ attributes.Add(attribute);
+ while (
+#line 220 "cs.ATG"
+NotFinalComma()) {
Expect(14);
- Attribute(out attribute);
- attributes.Add(attribute);
+ Attribute(
+#line 220 "cs.ATG"
+out attribute);
+
+#line 220 "cs.ATG"
+ attributes.Add(attribute);
}
if (la.kind == 14) {
- Get();
+ lexer.NextToken();
}
Expect(19);
+
+#line 222 "cs.ATG"
AttributeSection section = new AttributeSection {
AttributeTarget = attributeTarget,
Attributes = attributes,
@@ -113,24 +155,32 @@ partial class Parser : AbstractParser
EndLocation = t.EndLocation
};
compilationUnit.AddChild(section);
-
+
}
void NamespaceMemberDecl() {
+
+#line 326 "cs.ATG"
AttributeSection section;
List attributes = new List();
ModifierList m = new ModifierList();
string qualident;
-
+
if (la.kind == 88) {
- Get();
- Location startPos = t.Location;
- Qualident(out qualident);
+ lexer.NextToken();
+
+#line 332 "cs.ATG"
+ Location startPos = t.Location;
+ Qualident(
+#line 333 "cs.ATG"
+out qualident);
+
+#line 333 "cs.ATG"
INode node = new NamespaceDeclaration(qualident);
node.StartLocation = startPos;
compilationUnit.AddChild(node);
compilationUnit.BlockStart(node);
-
+
Expect(16);
while (la.kind == 71) {
ExternAliasDirective();
@@ -143,203 +193,285 @@ partial class Parser : AbstractParser
}
Expect(17);
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
+
+#line 343 "cs.ATG"
node.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
-
+
} else if (StartOf(2)) {
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 347 "cs.ATG"
+out section);
+
+#line 347 "cs.ATG"
+ attributes.Add(section);
}
while (StartOf(3)) {
- TypeModifier(m);
+ TypeModifier(
+#line 348 "cs.ATG"
+m);
}
- TypeDecl(m, attributes);
+ TypeDecl(
+#line 349 "cs.ATG"
+m, attributes);
} else SynErr(146);
}
- void Qualident(out string qualident) {
+ void Qualident(
+#line 483 "cs.ATG"
+out string qualident) {
Identifier();
- qualidentBuilder.Length = 0; qualidentBuilder.Append(t.val);
- while (DotAndIdent()) {
+
+#line 485 "cs.ATG"
+ qualidentBuilder.Length = 0; qualidentBuilder.Append(t.val);
+ while (
+#line 486 "cs.ATG"
+DotAndIdent()) {
Expect(15);
Identifier();
+
+#line 486 "cs.ATG"
qualidentBuilder.Append('.');
qualidentBuilder.Append(t.val);
-
+
}
- qualident = qualidentBuilder.ToString();
+
+#line 489 "cs.ATG"
+ qualident = qualidentBuilder.ToString();
}
- void NonArrayType(out TypeReference type) {
+ void NonArrayType(
+#line 601 "cs.ATG"
+out TypeReference type) {
+
+#line 603 "cs.ATG"
Location startPos = la.Location;
string name;
int pointer = 0;
type = null;
-
+
if (StartOf(4)) {
- ClassType(out type, false);
+ ClassType(
+#line 609 "cs.ATG"
+out type, false);
} else if (StartOf(5)) {
- SimpleType(out name);
- type = new TypeReference(name, true);
+ SimpleType(
+#line 610 "cs.ATG"
+out name);
+
+#line 610 "cs.ATG"
+ type = new TypeReference(name, true);
} else if (la.kind == 123) {
- Get();
+ lexer.NextToken();
Expect(6);
- pointer = 1; type = new TypeReference("System.Void", true);
+
+#line 611 "cs.ATG"
+ pointer = 1; type = new TypeReference("System.Void", true);
} else SynErr(147);
if (la.kind == 12) {
- NullableQuestionMark(ref type);
+ NullableQuestionMark(
+#line 614 "cs.ATG"
+ref type);
}
- while (IsPointer()) {
+ while (
+#line 616 "cs.ATG"
+IsPointer()) {
Expect(6);
- ++pointer;
+
+#line 617 "cs.ATG"
+ ++pointer;
}
+
+#line 619 "cs.ATG"
if (type != null) {
type.PointerNestingLevel = pointer;
type.EndLocation = t.EndLocation;
type.StartLocation = startPos;
}
-
+
}
void Identifier() {
switch (la.kind) {
case 1: {
- Get();
+ lexer.NextToken();
break;
}
case 126: {
- Get();
+ lexer.NextToken();
break;
}
case 127: {
- Get();
+ lexer.NextToken();
break;
}
case 128: {
- Get();
+ lexer.NextToken();
break;
}
case 129: {
- Get();
+ lexer.NextToken();
break;
}
case 130: {
- Get();
+ lexer.NextToken();
break;
}
case 131: {
- Get();
+ lexer.NextToken();
break;
}
case 132: {
- Get();
+ lexer.NextToken();
break;
}
case 133: {
- Get();
+ lexer.NextToken();
break;
}
case 134: {
- Get();
+ lexer.NextToken();
break;
}
case 135: {
- Get();
+ lexer.NextToken();
break;
}
case 136: {
- Get();
+ lexer.NextToken();
break;
}
case 137: {
- Get();
+ lexer.NextToken();
break;
}
case 138: {
- Get();
+ lexer.NextToken();
break;
}
case 139: {
- Get();
+ lexer.NextToken();
break;
}
case 140: {
- Get();
+ lexer.NextToken();
break;
}
case 141: {
- Get();
+ lexer.NextToken();
break;
}
case 142: {
- Get();
+ lexer.NextToken();
break;
}
case 143: {
- Get();
+ lexer.NextToken();
break;
}
case 144: {
- Get();
+ lexer.NextToken();
break;
}
default: SynErr(148); break;
}
}
- void Attribute(out ASTAttribute attribute) {
+ void Attribute(
+#line 232 "cs.ATG"
+out ASTAttribute attribute) {
+
+#line 233 "cs.ATG"
string qualident;
string alias = null;
+
- Location startPos = la.Location;
- if (IdentAndDoubleColon()) {
+#line 237 "cs.ATG"
+ Location startPos = la.Location;
+ if (
+#line 238 "cs.ATG"
+IdentAndDoubleColon()) {
Identifier();
- alias = t.val;
+
+#line 239 "cs.ATG"
+ alias = t.val;
Expect(10);
}
- Qualident(out qualident);
+ Qualident(
+#line 242 "cs.ATG"
+out qualident);
+
+#line 243 "cs.ATG"
List positional = new List();
List named = new List();
string name = (alias != null && alias != "global") ? alias + "." + qualident : qualident;
-
+
if (la.kind == 20) {
- AttributeArguments(positional, named);
+ AttributeArguments(
+#line 247 "cs.ATG"
+positional, named);
}
+
+#line 248 "cs.ATG"
attribute = new ASTAttribute(name, positional, named);
attribute.StartLocation = startPos;
attribute.EndLocation = t.EndLocation;
-
+
}
- void AttributeArguments(List positional, List named) {
+ void AttributeArguments(
+#line 254 "cs.ATG"
+List positional, List named) {
Expect(20);
if (StartOf(6)) {
- AttributeArgument(positional, named);
+ AttributeArgument(
+#line 258 "cs.ATG"
+positional, named);
while (la.kind == 14) {
- Get();
- AttributeArgument(positional, named);
+ lexer.NextToken();
+ AttributeArgument(
+#line 261 "cs.ATG"
+positional, named);
}
}
Expect(21);
}
- void AttributeArgument(List positional, List named) {
- string name = null; bool isNamed = false; Expression expr;
- if (IsAssignment()) {
- isNamed = true;
+ void AttributeArgument(
+#line 267 "cs.ATG"
+List positional, List named) {
+
+#line 268 "cs.ATG"
+ string name = null; bool isNamed = false; Expression expr;
+ if (
+#line 271 "cs.ATG"
+IsAssignment()) {
+
+#line 271 "cs.ATG"
+ isNamed = true;
Identifier();
- name = t.val;
+
+#line 272 "cs.ATG"
+ name = t.val;
Expect(3);
- } else if (IdentAndColon()) {
+ } else if (
+#line 275 "cs.ATG"
+IdentAndColon()) {
Identifier();
- name = t.val;
+
+#line 276 "cs.ATG"
+ name = t.val;
Expect(9);
} else if (StartOf(6)) {
} else SynErr(149);
- Expr(out expr);
+ Expr(
+#line 280 "cs.ATG"
+out expr);
+
+#line 282 "cs.ATG"
if (expr != null) {
if (isNamed) {
named.Add(new NamedArgumentExpression(name, expr));
@@ -351,335 +483,543 @@ partial class Parser : AbstractParser
positional.Add(expr);
}
}
-
+
}
- void Expr(out Expression expr) {
- expr = null; Expression expr1 = null, expr2 = null; AssignmentOperatorType op;
- Location startLocation = la.Location;
- UnaryExpr(out expr);
+ void Expr(
+#line 1780 "cs.ATG"
+out Expression expr) {
+
+#line 1781 "cs.ATG"
+ expr = null; Expression expr1 = null, expr2 = null; AssignmentOperatorType op;
+
+#line 1783 "cs.ATG"
+ Location startLocation = la.Location;
+ UnaryExpr(
+#line 1784 "cs.ATG"
+out expr);
if (StartOf(7)) {
- AssignmentOperator(out op);
- Expr(out expr1);
- expr = new AssignmentExpression(expr, op, expr1);
- } else if (la.kind == Tokens.GreaterThan && Peek(1).kind == Tokens.GreaterEqual) {
- AssignmentOperator(out op);
- Expr(out expr1);
- expr = new AssignmentExpression(expr, op, expr1);
+ AssignmentOperator(
+#line 1787 "cs.ATG"
+out op);
+ Expr(
+#line 1787 "cs.ATG"
+out expr1);
+
+#line 1787 "cs.ATG"
+ expr = new AssignmentExpression(expr, op, expr1);
+ } else if (
+#line 1788 "cs.ATG"
+la.kind == Tokens.GreaterThan && Peek(1).kind == Tokens.GreaterEqual) {
+ AssignmentOperator(
+#line 1789 "cs.ATG"
+out op);
+ Expr(
+#line 1789 "cs.ATG"
+out expr1);
+
+#line 1789 "cs.ATG"
+ expr = new AssignmentExpression(expr, op, expr1);
} else if (StartOf(8)) {
- ConditionalOrExpr(ref expr);
+ ConditionalOrExpr(
+#line 1791 "cs.ATG"
+ref expr);
if (la.kind == 13) {
- Get();
- Expr(out expr1);
- expr = new BinaryOperatorExpression(expr, BinaryOperatorType.NullCoalescing, expr1);
+ lexer.NextToken();
+ Expr(
+#line 1792 "cs.ATG"
+out expr1);
+
+#line 1792 "cs.ATG"
+ expr = new BinaryOperatorExpression(expr, BinaryOperatorType.NullCoalescing, expr1);
}
if (la.kind == 12) {
- Get();
- Expr(out expr1);
+ lexer.NextToken();
+ Expr(
+#line 1793 "cs.ATG"
+out expr1);
Expect(9);
- Expr(out expr2);
- expr = new ConditionalExpression(expr, expr1, expr2);
+ Expr(
+#line 1793 "cs.ATG"
+out expr2);
+
+#line 1793 "cs.ATG"
+ expr = new ConditionalExpression(expr, expr1, expr2);
}
} else SynErr(150);
+
+#line 1796 "cs.ATG"
if (expr != null) {
if (expr.StartLocation.IsEmpty)
expr.StartLocation = startLocation;
if (expr.EndLocation.IsEmpty)
expr.EndLocation = t.EndLocation;
}
-
+
}
- void AttributeSection(out AttributeSection section) {
+ void AttributeSection(
+#line 296 "cs.ATG"
+out AttributeSection section) {
+
+#line 298 "cs.ATG"
string attributeTarget = "";
List attributes = new List();
ASTAttribute attribute;
-
-
+
+
Expect(18);
- Location startPos = t.Location;
- if (IsLocalAttrTarget()) {
+
+#line 304 "cs.ATG"
+ Location startPos = t.Location;
+ if (
+#line 305 "cs.ATG"
+IsLocalAttrTarget()) {
if (la.kind == 69) {
- Get();
+ lexer.NextToken();
+
+#line 306 "cs.ATG"
attributeTarget = "event";
} else if (la.kind == 101) {
- Get();
+ lexer.NextToken();
+
+#line 307 "cs.ATG"
attributeTarget = "return";
- } else if (StartOf(9)) {
+ } else {
Identifier();
- attributeTarget = t.val;
- } else SynErr(151);
+
+#line 308 "cs.ATG"
+ attributeTarget = t.val;
+ }
Expect(9);
}
- Attribute(out attribute);
- attributes.Add(attribute);
- while (NotFinalComma()) {
+ Attribute(
+#line 312 "cs.ATG"
+out attribute);
+
+#line 312 "cs.ATG"
+ attributes.Add(attribute);
+ while (
+#line 313 "cs.ATG"
+NotFinalComma()) {
Expect(14);
- Attribute(out attribute);
- attributes.Add(attribute);
+ Attribute(
+#line 313 "cs.ATG"
+out attribute);
+
+#line 313 "cs.ATG"
+ attributes.Add(attribute);
}
if (la.kind == 14) {
- Get();
+ lexer.NextToken();
}
Expect(19);
+
+#line 315 "cs.ATG"
section = new AttributeSection {
AttributeTarget = attributeTarget,
Attributes = attributes,
StartLocation = startPos,
EndLocation = t.EndLocation
};
-
+
}
- void TypeModifier(ModifierList m) {
+ void TypeModifier(
+#line 686 "cs.ATG"
+ModifierList m) {
switch (la.kind) {
case 89: {
- Get();
- m.Add(Modifiers.New, t.Location);
+ lexer.NextToken();
+
+#line 688 "cs.ATG"
+ m.Add(Modifiers.New, t.Location);
break;
}
case 98: {
- Get();
- m.Add(Modifiers.Public, t.Location);
+ lexer.NextToken();
+
+#line 689 "cs.ATG"
+ m.Add(Modifiers.Public, t.Location);
break;
}
case 97: {
- Get();
- m.Add(Modifiers.Protected, t.Location);
+ lexer.NextToken();
+
+#line 690 "cs.ATG"
+ m.Add(Modifiers.Protected, t.Location);
break;
}
case 84: {
- Get();
- m.Add(Modifiers.Internal, t.Location);
+ lexer.NextToken();
+
+#line 691 "cs.ATG"
+ m.Add(Modifiers.Internal, t.Location);
break;
}
case 96: {
- Get();
- m.Add(Modifiers.Private, t.Location);
+ lexer.NextToken();
+
+#line 692 "cs.ATG"
+ m.Add(Modifiers.Private, t.Location);
break;
}
case 119: {
- Get();
- m.Add(Modifiers.Unsafe, t.Location);
+ lexer.NextToken();
+
+#line 693 "cs.ATG"
+ m.Add(Modifiers.Unsafe, t.Location);
break;
}
case 49: {
- Get();
- m.Add(Modifiers.Abstract, t.Location);
+ lexer.NextToken();
+
+#line 694 "cs.ATG"
+ m.Add(Modifiers.Abstract, t.Location);
break;
}
case 103: {
- Get();
- m.Add(Modifiers.Sealed, t.Location);
+ lexer.NextToken();
+
+#line 695 "cs.ATG"
+ m.Add(Modifiers.Sealed, t.Location);
break;
}
case 107: {
- Get();
- m.Add(Modifiers.Static, t.Location);
+ lexer.NextToken();
+
+#line 696 "cs.ATG"
+ m.Add(Modifiers.Static, t.Location);
break;
}
case 126: {
- Get();
- m.Add(Modifiers.Partial, t.Location);
+ lexer.NextToken();
+
+#line 697 "cs.ATG"
+ m.Add(Modifiers.Partial, t.Location);
break;
}
- default: SynErr(152); break;
+ default: SynErr(151); break;
}
}
- void TypeDecl(ModifierList m, List attributes) {
+ void TypeDecl(
+#line 362 "cs.ATG"
+ModifierList m, List attributes) {
+
+#line 364 "cs.ATG"
TypeReference type;
List names;
List p = new List();
string name;
List templates;
-
+
if (la.kind == 59) {
- m.Check(Modifiers.Classes);
- Get();
+
+#line 370 "cs.ATG"
+ m.Check(Modifiers.Classes);
+ lexer.NextToken();
+
+#line 371 "cs.ATG"
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
templates = newType.Templates;
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
-
+
newType.Type = Types.Class;
-
+
Identifier();
- newType.Name = t.val;
+
+#line 379 "cs.ATG"
+ newType.Name = t.val;
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 382 "cs.ATG"
+templates);
}
if (la.kind == 9) {
- ClassBase(out names);
- newType.BaseTypes = names;
+ ClassBase(
+#line 384 "cs.ATG"
+out names);
+
+#line 384 "cs.ATG"
+ newType.BaseTypes = names;
}
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 387 "cs.ATG"
+templates);
}
- newType.BodyStartLocation = t.EndLocation;
+
+#line 389 "cs.ATG"
+ newType.BodyStartLocation = t.EndLocation;
Expect(16);
ClassBody();
Expect(17);
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
+
+#line 393 "cs.ATG"
newType.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
+
+ } else if (StartOf(9)) {
- } else if (StartOf(10)) {
- m.Check(Modifiers.StructsInterfacesEnumsDelegates);
+#line 396 "cs.ATG"
+ m.Check(Modifiers.StructsInterfacesEnumsDelegates);
if (la.kind == 109) {
- Get();
+ lexer.NextToken();
+
+#line 397 "cs.ATG"
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
templates = newType.Templates;
newType.StartLocation = m.GetDeclarationLocation(t.Location);
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.Type = Types.Struct;
-
+
Identifier();
- newType.Name = t.val;
+
+#line 404 "cs.ATG"
+ newType.Name = t.val;
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 407 "cs.ATG"
+templates);
}
if (la.kind == 9) {
- StructInterfaces(out names);
- newType.BaseTypes = names;
+ StructInterfaces(
+#line 409 "cs.ATG"
+out names);
+
+#line 409 "cs.ATG"
+ newType.BaseTypes = names;
}
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 412 "cs.ATG"
+templates);
}
- newType.BodyStartLocation = t.EndLocation;
+
+#line 415 "cs.ATG"
+ newType.BodyStartLocation = t.EndLocation;
StructBody();
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
+
+#line 417 "cs.ATG"
newType.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
-
+
} else if (la.kind == 83) {
- Get();
+ lexer.NextToken();
+
+#line 421 "cs.ATG"
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
templates = newType.Templates;
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
newType.Type = Types.Interface;
-
+
Identifier();
- newType.Name = t.val;
+
+#line 428 "cs.ATG"
+ newType.Name = t.val;
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 431 "cs.ATG"
+templates);
}
if (la.kind == 9) {
- InterfaceBase(out names);
- newType.BaseTypes = names;
+ InterfaceBase(
+#line 433 "cs.ATG"
+out names);
+
+#line 433 "cs.ATG"
+ newType.BaseTypes = names;
}
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 436 "cs.ATG"
+templates);
}
- newType.BodyStartLocation = t.EndLocation;
+
+#line 438 "cs.ATG"
+ newType.BodyStartLocation = t.EndLocation;
InterfaceBody();
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
+
+#line 440 "cs.ATG"
newType.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
-
+
} else if (la.kind == 68) {
- Get();
+ lexer.NextToken();
+
+#line 444 "cs.ATG"
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
newType.Type = Types.Enum;
-
+
Identifier();
- newType.Name = t.val;
+
+#line 450 "cs.ATG"
+ newType.Name = t.val;
if (la.kind == 9) {
- Get();
- IntegralType(out name);
- newType.BaseTypes.Add(new TypeReference(name, true));
+ lexer.NextToken();
+ IntegralType(
+#line 451 "cs.ATG"
+out name);
+
+#line 451 "cs.ATG"
+ newType.BaseTypes.Add(new TypeReference(name, true));
}
- newType.BodyStartLocation = t.EndLocation;
+
+#line 453 "cs.ATG"
+ newType.BodyStartLocation = t.EndLocation;
EnumBody();
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
+
+#line 455 "cs.ATG"
newType.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
-
+
} else {
- Get();
+ lexer.NextToken();
+
+#line 459 "cs.ATG"
DelegateDeclaration delegateDeclr = new DelegateDeclaration(m.Modifier, attributes);
templates = delegateDeclr.Templates;
delegateDeclr.StartLocation = m.GetDeclarationLocation(t.Location);
-
- if (NotVoidPointer()) {
+
+ if (
+#line 463 "cs.ATG"
+NotVoidPointer()) {
Expect(123);
- delegateDeclr.ReturnType = new TypeReference("System.Void", true);
- } else if (StartOf(11)) {
- Type(out type);
- delegateDeclr.ReturnType = type;
- } else SynErr(153);
+
+#line 463 "cs.ATG"
+ delegateDeclr.ReturnType = new TypeReference("System.Void", true);
+ } else if (StartOf(10)) {
+ Type(
+#line 464 "cs.ATG"
+out type);
+
+#line 464 "cs.ATG"
+ delegateDeclr.ReturnType = type;
+ } else SynErr(152);
Identifier();
- delegateDeclr.Name = t.val;
+
+#line 466 "cs.ATG"
+ delegateDeclr.Name = t.val;
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 469 "cs.ATG"
+templates);
}
Expect(20);
- if (StartOf(12)) {
- FormalParameterList(p);
- delegateDeclr.Parameters = p;
+ if (StartOf(11)) {
+ FormalParameterList(
+#line 471 "cs.ATG"
+p);
+
+#line 471 "cs.ATG"
+ delegateDeclr.Parameters = p;
}
Expect(21);
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 475 "cs.ATG"
+templates);
}
Expect(11);
+
+#line 477 "cs.ATG"
delegateDeclr.EndLocation = t.EndLocation;
compilationUnit.AddChild(delegateDeclr);
-
+
}
- } else SynErr(154);
+ } else SynErr(153);
}
- void TypeParameterList(List templates) {
- TemplateDefinition template;
+ void TypeParameterList(
+#line 2361 "cs.ATG"
+List templates) {
+#line 2363 "cs.ATG"
+ TemplateDefinition template;
+
Expect(23);
- VariantTypeParameter(out template);
- templates.Add(template);
+ VariantTypeParameter(
+#line 2367 "cs.ATG"
+out template);
+
+#line 2367 "cs.ATG"
+ templates.Add(template);
while (la.kind == 14) {
- Get();
- VariantTypeParameter(out template);
- templates.Add(template);
+ lexer.NextToken();
+ VariantTypeParameter(
+#line 2369 "cs.ATG"
+out template);
+
+#line 2369 "cs.ATG"
+ templates.Add(template);
}
Expect(22);
}
- void ClassBase(out List names) {
+ void ClassBase(
+#line 492 "cs.ATG"
+out List names) {
+
+#line 494 "cs.ATG"
TypeReference typeRef;
names = new List();
-
+
Expect(9);
- ClassType(out typeRef, false);
- if (typeRef != null) { names.Add(typeRef); }
+ ClassType(
+#line 498 "cs.ATG"
+out typeRef, false);
+
+#line 498 "cs.ATG"
+ if (typeRef != null) { names.Add(typeRef); }
while (la.kind == 14) {
- Get();
- TypeName(out typeRef, false);
- if (typeRef != null) { names.Add(typeRef); }
+ lexer.NextToken();
+ TypeName(
+#line 499 "cs.ATG"
+out typeRef, false);
+
+#line 499 "cs.ATG"
+ if (typeRef != null) { names.Add(typeRef); }
}
}
- void TypeParameterConstraintsClause(List templates) {
- string name = ""; TypeReference type;
+ void TypeParameterConstraintsClause(
+#line 2389 "cs.ATG"
+List templates) {
+
+#line 2390 "cs.ATG"
+ string name = ""; TypeReference type;
Expect(127);
Identifier();
- name = t.val;
+
+#line 2393 "cs.ATG"
+ name = t.val;
Expect(9);
- TypeParameterConstraintsClauseBase(out type);
+ TypeParameterConstraintsClauseBase(
+#line 2395 "cs.ATG"
+out type);
+
+#line 2396 "cs.ATG"
TemplateDefinition td = null;
foreach (TemplateDefinition d in templates) {
if (d.Name == name) {
@@ -688,10 +1028,14 @@ partial class Parser : AbstractParser
}
}
if ( td != null && type != null) { td.Bases.Add(type); }
-
+
while (la.kind == 14) {
- Get();
- TypeParameterConstraintsClauseBase(out type);
+ lexer.NextToken();
+ TypeParameterConstraintsClauseBase(
+#line 2405 "cs.ATG"
+out type);
+
+#line 2406 "cs.ATG"
td = null;
foreach (TemplateDefinition d in templates) {
if (d.Name == name) {
@@ -700,208 +1044,342 @@ partial class Parser : AbstractParser
}
}
if ( td != null && type != null) { td.Bases.Add(type); }
-
+
}
}
void ClassBody() {
- AttributeSection section;
- while (StartOf(13)) {
+
+#line 503 "cs.ATG"
+ AttributeSection section;
+ while (StartOf(12)) {
+
+#line 505 "cs.ATG"
List attributes = new List();
ModifierList m = new ModifierList();
-
- while (!(StartOf(14))) {SynErr(155); Get();}
+
+ while (!(StartOf(13))) {SynErr(154); lexer.NextToken(); }
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 509 "cs.ATG"
+out section);
+
+#line 509 "cs.ATG"
+ attributes.Add(section);
}
- MemberModifiers(m);
- ClassMemberDecl(m, attributes);
+ MemberModifiers(
+#line 510 "cs.ATG"
+m);
+ ClassMemberDecl(
+#line 511 "cs.ATG"
+m, attributes);
}
}
- void StructInterfaces(out List names) {
+ void StructInterfaces(
+#line 515 "cs.ATG"
+out List names) {
+
+#line 517 "cs.ATG"
TypeReference typeRef;
names = new List();
-
+
Expect(9);
- TypeName(out typeRef, false);
- if (typeRef != null) { names.Add(typeRef); }
+ TypeName(
+#line 521 "cs.ATG"
+out typeRef, false);
+
+#line 521 "cs.ATG"
+ if (typeRef != null) { names.Add(typeRef); }
while (la.kind == 14) {
- Get();
- TypeName(out typeRef, false);
- if (typeRef != null) { names.Add(typeRef); }
+ lexer.NextToken();
+ TypeName(
+#line 522 "cs.ATG"
+out typeRef, false);
+
+#line 522 "cs.ATG"
+ if (typeRef != null) { names.Add(typeRef); }
}
}
void StructBody() {
- AttributeSection section;
+
+#line 526 "cs.ATG"
+ AttributeSection section;
Expect(16);
- while (StartOf(15)) {
+ while (StartOf(14)) {
+
+#line 529 "cs.ATG"
List attributes = new List();
ModifierList m = new ModifierList();
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 532 "cs.ATG"
+out section);
+
+#line 532 "cs.ATG"
+ attributes.Add(section);
}
- MemberModifiers(m);
- StructMemberDecl(m, attributes);
+ MemberModifiers(
+#line 533 "cs.ATG"
+m);
+ StructMemberDecl(
+#line 534 "cs.ATG"
+m, attributes);
}
Expect(17);
}
- void InterfaceBase(out List names) {
+ void InterfaceBase(
+#line 539 "cs.ATG"
+out List names) {
+
+#line 541 "cs.ATG"
TypeReference typeRef;
names = new List();
-
+
Expect(9);
- TypeName(out typeRef, false);
- if (typeRef != null) { names.Add(typeRef); }
+ TypeName(
+#line 545 "cs.ATG"
+out typeRef, false);
+
+#line 545 "cs.ATG"
+ if (typeRef != null) { names.Add(typeRef); }
while (la.kind == 14) {
- Get();
- TypeName(out typeRef, false);
- if (typeRef != null) { names.Add(typeRef); }
+ lexer.NextToken();
+ TypeName(
+#line 546 "cs.ATG"
+out typeRef, false);
+
+#line 546 "cs.ATG"
+ if (typeRef != null) { names.Add(typeRef); }
}
}
void InterfaceBody() {
Expect(16);
- while (StartOf(16)) {
- while (!(StartOf(17))) {SynErr(156); Get();}
+ while (StartOf(15)) {
+ while (!(StartOf(16))) {SynErr(155); lexer.NextToken(); }
InterfaceMemberDecl();
}
Expect(17);
}
- void IntegralType(out string name) {
- name = "";
+ void IntegralType(
+#line 708 "cs.ATG"
+out string name) {
+
+#line 708 "cs.ATG"
+ name = "";
switch (la.kind) {
case 102: {
- Get();
- name = "System.SByte";
+ lexer.NextToken();
+
+#line 710 "cs.ATG"
+ name = "System.SByte";
break;
}
case 54: {
- Get();
- name = "System.Byte";
+ lexer.NextToken();
+
+#line 711 "cs.ATG"
+ name = "System.Byte";
break;
}
case 104: {
- Get();
- name = "System.Int16";
+ lexer.NextToken();
+
+#line 712 "cs.ATG"
+ name = "System.Int16";
break;
}
case 120: {
- Get();
- name = "System.UInt16";
+ lexer.NextToken();
+
+#line 713 "cs.ATG"
+ name = "System.UInt16";
break;
}
case 82: {
- Get();
- name = "System.Int32";
+ lexer.NextToken();
+
+#line 714 "cs.ATG"
+ name = "System.Int32";
break;
}
case 116: {
- Get();
- name = "System.UInt32";
+ lexer.NextToken();
+
+#line 715 "cs.ATG"
+ name = "System.UInt32";
break;
}
case 87: {
- Get();
- name = "System.Int64";
+ lexer.NextToken();
+
+#line 716 "cs.ATG"
+ name = "System.Int64";
break;
}
case 117: {
- Get();
- name = "System.UInt64";
+ lexer.NextToken();
+
+#line 717 "cs.ATG"
+ name = "System.UInt64";
break;
}
case 57: {
- Get();
- name = "System.Char";
+ lexer.NextToken();
+
+#line 718 "cs.ATG"
+ name = "System.Char";
break;
}
- default: SynErr(157); break;
+ default: SynErr(156); break;
}
}
void EnumBody() {
- FieldDeclaration f;
+
+#line 555 "cs.ATG"
+ FieldDeclaration f;
Expect(16);
- if (StartOf(18)) {
- EnumMemberDecl(out f);
- compilationUnit.AddChild(f);
- while (NotFinalComma()) {
+ if (StartOf(17)) {
+ EnumMemberDecl(
+#line 558 "cs.ATG"
+out f);
+
+#line 558 "cs.ATG"
+ compilationUnit.AddChild(f);
+ while (
+#line 559 "cs.ATG"
+NotFinalComma()) {
Expect(14);
- EnumMemberDecl(out f);
- compilationUnit.AddChild(f);
+ EnumMemberDecl(
+#line 560 "cs.ATG"
+out f);
+
+#line 560 "cs.ATG"
+ compilationUnit.AddChild(f);
}
if (la.kind == 14) {
- Get();
+ lexer.NextToken();
}
}
Expect(17);
}
- void Type(out TypeReference type) {
- TypeWithRestriction(out type, true, false);
+ void Type(
+#line 566 "cs.ATG"
+out TypeReference type) {
+ TypeWithRestriction(
+#line 568 "cs.ATG"
+out type, true, false);
}
- void FormalParameterList(List parameter) {
+ void FormalParameterList(
+#line 638 "cs.ATG"
+List parameter) {
+
+#line 641 "cs.ATG"
ParameterDeclarationExpression p;
AttributeSection section;
List attributes = new List();
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 646 "cs.ATG"
+out section);
+
+#line 646 "cs.ATG"
+ attributes.Add(section);
}
- FixedParameter(out p);
+ FixedParameter(
+#line 647 "cs.ATG"
+out p);
+
+#line 647 "cs.ATG"
p.Attributes = attributes;
parameter.Add(p);
-
+
while (la.kind == 14) {
- Get();
- attributes = new List();
+ lexer.NextToken();
+
+#line 651 "cs.ATG"
+ attributes = new List();
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 652 "cs.ATG"
+out section);
+
+#line 652 "cs.ATG"
+ attributes.Add(section);
}
- FixedParameter(out p);
- p.Attributes = attributes; parameter.Add(p);
+ FixedParameter(
+#line 653 "cs.ATG"
+out p);
+
+#line 653 "cs.ATG"
+ p.Attributes = attributes; parameter.Add(p);
}
}
- void ClassType(out TypeReference typeRef, bool canBeUnbound) {
- TypeReference r; typeRef = null;
- if (StartOf(9)) {
- TypeName(out r, canBeUnbound);
- typeRef = r;
+ void ClassType(
+#line 700 "cs.ATG"
+out TypeReference typeRef, bool canBeUnbound) {
+
+#line 701 "cs.ATG"
+ TypeReference r; typeRef = null;
+ if (StartOf(18)) {
+ TypeName(
+#line 703 "cs.ATG"
+out r, canBeUnbound);
+
+#line 703 "cs.ATG"
+ typeRef = r;
} else if (la.kind == 91) {
- Get();
- typeRef = new TypeReference("System.Object", true); typeRef.StartLocation = t.Location;
+ lexer.NextToken();
+
+#line 704 "cs.ATG"
+ typeRef = new TypeReference("System.Object", true); typeRef.StartLocation = t.Location;
} else if (la.kind == 108) {
- Get();
- typeRef = new TypeReference("System.String", true); typeRef.StartLocation = t.Location;
- } else SynErr(158);
+ lexer.NextToken();
+
+#line 705 "cs.ATG"
+ typeRef = new TypeReference("System.String", true); typeRef.StartLocation = t.Location;
+ } else SynErr(157);
}
- void TypeName(out TypeReference typeRef, bool canBeUnbound) {
+ void TypeName(
+#line 2302 "cs.ATG"
+out TypeReference typeRef, bool canBeUnbound) {
+
+#line 2303 "cs.ATG"
List typeArguments = null;
string alias = null;
string qualident;
Location startLocation = la.Location;
-
- if (IdentAndDoubleColon()) {
+
+ if (
+#line 2309 "cs.ATG"
+IdentAndDoubleColon()) {
Identifier();
- alias = t.val;
+
+#line 2310 "cs.ATG"
+ alias = t.val;
Expect(10);
}
- Qualident(out qualident);
+ Qualident(
+#line 2313 "cs.ATG"
+out qualident);
if (la.kind == 23) {
- TypeArgumentList(out typeArguments, canBeUnbound);
+ TypeArgumentList(
+#line 2314 "cs.ATG"
+out typeArguments, canBeUnbound);
}
+
+#line 2316 "cs.ATG"
if (alias == null) {
typeRef = new TypeReference(qualident, typeArguments);
} else if (alias == "global") {
@@ -910,133 +1388,199 @@ partial class Parser : AbstractParser
} else {
typeRef = new TypeReference(alias + "." + qualident, typeArguments);
}
-
- while (DotAndIdent()) {
+
+ while (
+#line 2325 "cs.ATG"
+DotAndIdent()) {
Expect(15);
- typeArguments = null;
- Qualident(out qualident);
+
+#line 2326 "cs.ATG"
+ typeArguments = null;
+ Qualident(
+#line 2327 "cs.ATG"
+out qualident);
if (la.kind == 23) {
- TypeArgumentList(out typeArguments, canBeUnbound);
+ TypeArgumentList(
+#line 2328 "cs.ATG"
+out typeArguments, canBeUnbound);
}
- typeRef = new InnerClassTypeReference(typeRef, qualident, typeArguments);
+
+#line 2329 "cs.ATG"
+ typeRef = new InnerClassTypeReference(typeRef, qualident, typeArguments);
}
- typeRef.StartLocation = startLocation;
+
+#line 2331 "cs.ATG"
+ typeRef.StartLocation = startLocation;
}
- void MemberModifiers(ModifierList m) {
+ void MemberModifiers(
+#line 721 "cs.ATG"
+ModifierList m) {
while (StartOf(19)) {
switch (la.kind) {
case 49: {
- Get();
- m.Add(Modifiers.Abstract, t.Location);
+ lexer.NextToken();
+
+#line 724 "cs.ATG"
+ m.Add(Modifiers.Abstract, t.Location);
break;
}
case 71: {
- Get();
- m.Add(Modifiers.Extern, t.Location);
+ lexer.NextToken();
+
+#line 725 "cs.ATG"
+ m.Add(Modifiers.Extern, t.Location);
break;
}
case 84: {
- Get();
- m.Add(Modifiers.Internal, t.Location);
+ lexer.NextToken();
+
+#line 726 "cs.ATG"
+ m.Add(Modifiers.Internal, t.Location);
break;
}
case 89: {
- Get();
- m.Add(Modifiers.New, t.Location);
+ lexer.NextToken();
+
+#line 727 "cs.ATG"
+ m.Add(Modifiers.New, t.Location);
break;
}
case 94: {
- Get();
- m.Add(Modifiers.Override, t.Location);
+ lexer.NextToken();
+
+#line 728 "cs.ATG"
+ m.Add(Modifiers.Override, t.Location);
break;
}
case 96: {
- Get();
- m.Add(Modifiers.Private, t.Location);
+ lexer.NextToken();
+
+#line 729 "cs.ATG"
+ m.Add(Modifiers.Private, t.Location);
break;
}
case 97: {
- Get();
- m.Add(Modifiers.Protected, t.Location);
+ lexer.NextToken();
+
+#line 730 "cs.ATG"
+ m.Add(Modifiers.Protected, t.Location);
break;
}
case 98: {
- Get();
- m.Add(Modifiers.Public, t.Location);
+ lexer.NextToken();
+
+#line 731 "cs.ATG"
+ m.Add(Modifiers.Public, t.Location);
break;
}
case 99: {
- Get();
- m.Add(Modifiers.ReadOnly, t.Location);
+ lexer.NextToken();
+
+#line 732 "cs.ATG"
+ m.Add(Modifiers.ReadOnly, t.Location);
break;
}
case 103: {
- Get();
- m.Add(Modifiers.Sealed, t.Location);
+ lexer.NextToken();
+
+#line 733 "cs.ATG"
+ m.Add(Modifiers.Sealed, t.Location);
break;
}
case 107: {
- Get();
- m.Add(Modifiers.Static, t.Location);
+ lexer.NextToken();
+
+#line 734 "cs.ATG"
+ m.Add(Modifiers.Static, t.Location);
break;
}
case 74: {
- Get();
- m.Add(Modifiers.Fixed, t.Location);
+ lexer.NextToken();
+
+#line 735 "cs.ATG"
+ m.Add(Modifiers.Fixed, t.Location);
break;
}
case 119: {
- Get();
- m.Add(Modifiers.Unsafe, t.Location);
+ lexer.NextToken();
+
+#line 736 "cs.ATG"
+ m.Add(Modifiers.Unsafe, t.Location);
break;
}
case 122: {
- Get();
- m.Add(Modifiers.Virtual, t.Location);
+ lexer.NextToken();
+
+#line 737 "cs.ATG"
+ m.Add(Modifiers.Virtual, t.Location);
break;
}
case 124: {
- Get();
- m.Add(Modifiers.Volatile, t.Location);
+ lexer.NextToken();
+
+#line 738 "cs.ATG"
+ m.Add(Modifiers.Volatile, t.Location);
break;
}
case 126: {
- Get();
- m.Add(Modifiers.Partial, t.Location);
+ lexer.NextToken();
+
+#line 739 "cs.ATG"
+ m.Add(Modifiers.Partial, t.Location);
break;
}
}
}
}
- void ClassMemberDecl(ModifierList m, List attributes) {
- Statement stmt = null;
+ void ClassMemberDecl(
+#line 1057 "cs.ATG"
+ModifierList m, List attributes) {
+
+#line 1058 "cs.ATG"
+ Statement stmt = null;
if (StartOf(20)) {
- StructMemberDecl(m, attributes);
+ StructMemberDecl(
+#line 1060 "cs.ATG"
+m, attributes);
} else if (la.kind == 27) {
- m.Check(Modifiers.Destructors); Location startPos = la.Location;
- Get();
+
+#line 1061 "cs.ATG"
+ m.Check(Modifiers.Destructors); Location startPos = la.Location;
+ lexer.NextToken();
Identifier();
+
+#line 1062 "cs.ATG"
DestructorDeclaration d = new DestructorDeclaration(t.val, m.Modifier, attributes);
d.Modifier = m.Modifier;
d.StartLocation = m.GetDeclarationLocation(startPos);
-
+
Expect(20);
Expect(21);
- d.EndLocation = t.EndLocation;
+
+#line 1066 "cs.ATG"
+ d.EndLocation = t.EndLocation;
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 1066 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(159);
+ lexer.NextToken();
+ } else SynErr(158);
+
+#line 1067 "cs.ATG"
d.Body = (BlockStatement)stmt;
compilationUnit.AddChild(d);
-
- } else SynErr(160);
+
+ } else SynErr(159);
}
- void StructMemberDecl(ModifierList m, List attributes) {
+ void StructMemberDecl(
+#line 743 "cs.ATG"
+ModifierList m, List attributes) {
+
+#line 745 "cs.ATG"
string qualident = null;
TypeReference type;
Expression expr;
@@ -1045,62 +1589,104 @@ partial class Parser : AbstractParser
List templates = new List();
TypeReference explicitInterface = null;
bool isExtensionMethod = false;
-
+
if (la.kind == 60) {
- m.Check(Modifiers.Constants);
- Get();
- Location startPos = t.Location;
- Type(out type);
+
+#line 755 "cs.ATG"
+ m.Check(Modifiers.Constants);
+ lexer.NextToken();
+
+#line 756 "cs.ATG"
+ Location startPos = t.Location;
+ Type(
+#line 757 "cs.ATG"
+out type);
Identifier();
+
+#line 757 "cs.ATG"
FieldDeclaration fd = new FieldDeclaration(attributes, type, m.Modifier | Modifiers.Const);
fd.StartLocation = m.GetDeclarationLocation(startPos);
VariableDeclaration f = new VariableDeclaration(t.val);
f.StartLocation = t.Location;
f.TypeReference = type;
SafeAdd(fd, fd.Fields, f);
-
+
Expect(3);
- Expr(out expr);
- f.Initializer = expr;
+ Expr(
+#line 764 "cs.ATG"
+out expr);
+
+#line 764 "cs.ATG"
+ f.Initializer = expr;
while (la.kind == 14) {
- Get();
+ lexer.NextToken();
Identifier();
+
+#line 765 "cs.ATG"
f = new VariableDeclaration(t.val);
f.StartLocation = t.Location;
f.TypeReference = type;
SafeAdd(fd, fd.Fields, f);
-
+
Expect(3);
- Expr(out expr);
- f.EndLocation = t.EndLocation; f.Initializer = expr;
+ Expr(
+#line 770 "cs.ATG"
+out expr);
+
+#line 770 "cs.ATG"
+ f.EndLocation = t.EndLocation; f.Initializer = expr;
}
Expect(11);
- fd.EndLocation = t.EndLocation; compilationUnit.AddChild(fd);
- } else if (NotVoidPointer()) {
- m.Check(Modifiers.PropertysEventsMethods);
+
+#line 771 "cs.ATG"
+ fd.EndLocation = t.EndLocation; compilationUnit.AddChild(fd);
+ } else if (
+#line 775 "cs.ATG"
+NotVoidPointer()) {
+
+#line 775 "cs.ATG"
+ m.Check(Modifiers.PropertysEventsMethods);
Expect(123);
- Location startPos = t.Location;
- if (IsExplicitInterfaceImplementation()) {
- TypeName(out explicitInterface, false);
+
+#line 776 "cs.ATG"
+ Location startPos = t.Location;
+ if (
+#line 777 "cs.ATG"
+IsExplicitInterfaceImplementation()) {
+ TypeName(
+#line 778 "cs.ATG"
+out explicitInterface, false);
+
+#line 779 "cs.ATG"
if (la.kind != Tokens.Dot || Peek(1).kind != Tokens.This) {
qualident = TypeReference.StripLastIdentifierFromType(ref explicitInterface);
- }
- } else if (StartOf(9)) {
+ }
+ } else if (StartOf(18)) {
Identifier();
- qualident = t.val;
- } else SynErr(161);
+
+#line 782 "cs.ATG"
+ qualident = t.val;
+ } else SynErr(160);
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 785 "cs.ATG"
+templates);
}
Expect(20);
if (la.kind == 111) {
- Get();
- isExtensionMethod = true; /* C# 3.0 */
+ lexer.NextToken();
+
+#line 788 "cs.ATG"
+ isExtensionMethod = true; /* C# 3.0 */
}
- if (StartOf(12)) {
- FormalParameterList(p);
+ if (StartOf(11)) {
+ FormalParameterList(
+#line 789 "cs.ATG"
+p);
}
Expect(21);
+
+#line 790 "cs.ATG"
MethodDeclaration methodDeclaration = new MethodDeclaration {
Name = qualident,
Modifier = m.Modifier,
@@ -1116,21 +1702,31 @@ partial class Parser : AbstractParser
SafeAdd(methodDeclaration, methodDeclaration.InterfaceImplementations, new InterfaceImplementation(explicitInterface, qualident));
compilationUnit.AddChild(methodDeclaration);
compilationUnit.BlockStart(methodDeclaration);
-
+
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 808 "cs.ATG"
+templates);
}
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 810 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(162);
+ lexer.NextToken();
+ } else SynErr(161);
+
+#line 810 "cs.ATG"
compilationUnit.BlockEnd();
methodDeclaration.Body = (BlockStatement)stmt;
-
+
} else if (la.kind == 69) {
- m.Check(Modifiers.PropertysEventsMethods);
- Get();
+
+#line 814 "cs.ATG"
+ m.Check(Modifiers.PropertysEventsMethods);
+ lexer.NextToken();
+
+#line 816 "cs.ATG"
EventDeclaration eventDecl = new EventDeclaration {
Modifier = m.Modifier,
Attributes = attributes,
@@ -1140,90 +1736,162 @@ partial class Parser : AbstractParser
compilationUnit.BlockStart(eventDecl);
EventAddRegion addBlock = null;
EventRemoveRegion removeBlock = null;
-
- Type(out type);
- eventDecl.TypeReference = type;
- if (IsExplicitInterfaceImplementation()) {
- TypeName(out explicitInterface, false);
- qualident = TypeReference.StripLastIdentifierFromType(ref explicitInterface);
- eventDecl.InterfaceImplementations.Add(new InterfaceImplementation(explicitInterface, qualident));
- } else if (StartOf(9)) {
+
+ Type(
+#line 826 "cs.ATG"
+out type);
+
+#line 826 "cs.ATG"
+ eventDecl.TypeReference = type;
+ if (
+#line 827 "cs.ATG"
+IsExplicitInterfaceImplementation()) {
+ TypeName(
+#line 828 "cs.ATG"
+out explicitInterface, false);
+
+#line 829 "cs.ATG"
+ qualident = TypeReference.StripLastIdentifierFromType(ref explicitInterface);
+
+#line 830 "cs.ATG"
+ eventDecl.InterfaceImplementations.Add(new InterfaceImplementation(explicitInterface, qualident));
+ } else if (StartOf(18)) {
Identifier();
- qualident = t.val;
- } else SynErr(163);
- eventDecl.Name = qualident; eventDecl.EndLocation = t.EndLocation;
+
+#line 832 "cs.ATG"
+ qualident = t.val;
+ } else SynErr(162);
+
+#line 834 "cs.ATG"
+ eventDecl.Name = qualident; eventDecl.EndLocation = t.EndLocation;
if (la.kind == 3) {
- Get();
- Expr(out expr);
- eventDecl.Initializer = expr;
+ lexer.NextToken();
+ Expr(
+#line 835 "cs.ATG"
+out expr);
+
+#line 835 "cs.ATG"
+ eventDecl.Initializer = expr;
}
if (la.kind == 16) {
- Get();
- eventDecl.BodyStart = t.Location;
- EventAccessorDecls(out addBlock, out removeBlock);
+ lexer.NextToken();
+
+#line 836 "cs.ATG"
+ eventDecl.BodyStart = t.Location;
+ EventAccessorDecls(
+#line 837 "cs.ATG"
+out addBlock, out removeBlock);
Expect(17);
- eventDecl.BodyEnd = t.EndLocation;
+
+#line 838 "cs.ATG"
+ eventDecl.BodyEnd = t.EndLocation;
}
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
+
+#line 841 "cs.ATG"
compilationUnit.BlockEnd();
eventDecl.AddRegion = addBlock;
eventDecl.RemoveRegion = removeBlock;
+
+ } else if (
+#line 847 "cs.ATG"
+IdentAndLPar()) {
- } else if (IdentAndLPar()) {
- m.Check(Modifiers.Constructors | Modifiers.StaticConstructors);
+#line 847 "cs.ATG"
+ m.Check(Modifiers.Constructors | Modifiers.StaticConstructors);
Identifier();
- string name = t.val; Location startPos = t.Location;
+
+#line 848 "cs.ATG"
+ string name = t.val; Location startPos = t.Location;
Expect(20);
- if (StartOf(12)) {
- m.Check(Modifiers.Constructors);
- FormalParameterList(p);
+ if (StartOf(11)) {
+
+#line 848 "cs.ATG"
+ m.Check(Modifiers.Constructors);
+ FormalParameterList(
+#line 849 "cs.ATG"
+p);
}
Expect(21);
- ConstructorInitializer init = null;
+
+#line 851 "cs.ATG"
+ ConstructorInitializer init = null;
if (la.kind == 9) {
- m.Check(Modifiers.Constructors);
- ConstructorInitializer(out init);
+
+#line 852 "cs.ATG"
+ m.Check(Modifiers.Constructors);
+ ConstructorInitializer(
+#line 853 "cs.ATG"
+out init);
}
+
+#line 855 "cs.ATG"
ConstructorDeclaration cd = new ConstructorDeclaration(name, m.Modifier, p, init, attributes);
cd.StartLocation = startPos;
cd.EndLocation = t.EndLocation;
-
+
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 860 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(164);
- cd.Body = (BlockStatement)stmt; compilationUnit.AddChild(cd);
+ lexer.NextToken();
+ } else SynErr(163);
+
+#line 860 "cs.ATG"
+ cd.Body = (BlockStatement)stmt; compilationUnit.AddChild(cd);
} else if (la.kind == 70 || la.kind == 80) {
+
+#line 863 "cs.ATG"
m.Check(Modifiers.Operators);
if (m.isNone) Error("at least one modifier must be set");
bool isImplicit = true;
Location startPos = Location.Empty;
-
+
if (la.kind == 80) {
- Get();
- startPos = t.Location;
+ lexer.NextToken();
+
+#line 868 "cs.ATG"
+ startPos = t.Location;
} else {
- Get();
- isImplicit = false; startPos = t.Location;
+ lexer.NextToken();
+
+#line 868 "cs.ATG"
+ isImplicit = false; startPos = t.Location;
}
Expect(92);
- Type(out type);
- TypeReference operatorType = type;
+ Type(
+#line 869 "cs.ATG"
+out type);
+
+#line 869 "cs.ATG"
+ TypeReference operatorType = type;
Expect(20);
- Type(out type);
+ Type(
+#line 870 "cs.ATG"
+out type);
Identifier();
- string varName = t.val;
+
+#line 870 "cs.ATG"
+ string varName = t.val;
Expect(21);
- Location endPos = t.Location;
+
+#line 871 "cs.ATG"
+ Location endPos = t.Location;
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 872 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- stmt = null;
- } else SynErr(165);
+ lexer.NextToken();
+
+#line 872 "cs.ATG"
+ stmt = null;
+ } else SynErr(164);
+
+#line 875 "cs.ATG"
List parameters = new List();
parameters.Add(new ParameterDeclarationExpression(type, varName));
OperatorDeclaration operatorDeclaration = new OperatorDeclaration {
@@ -1238,38 +1906,64 @@ partial class Parser : AbstractParser
EndLocation = endPos
};
compilationUnit.AddChild(operatorDeclaration);
-
+
} else if (StartOf(21)) {
- TypeDecl(m, attributes);
- } else if (StartOf(11)) {
- Type(out type);
- Location startPos = t.Location;
+ TypeDecl(
+#line 893 "cs.ATG"
+m, attributes);
+ } else if (StartOf(10)) {
+ Type(
+#line 895 "cs.ATG"
+out type);
+
+#line 895 "cs.ATG"
+ Location startPos = t.Location;
if (la.kind == 92) {
+
+#line 897 "cs.ATG"
OverloadableOperatorType op;
m.Check(Modifiers.Operators);
if (m.isNone) Error("at least one modifier must be set");
-
- Get();
- OverloadableOperator(out op);
- TypeReference firstType, secondType = null; string secondName = null;
+
+ lexer.NextToken();
+ OverloadableOperator(
+#line 901 "cs.ATG"
+out op);
+
+#line 901 "cs.ATG"
+ TypeReference firstType, secondType = null; string secondName = null;
Expect(20);
- Type(out firstType);
+ Type(
+#line 902 "cs.ATG"
+out firstType);
Identifier();
- string firstName = t.val;
+
+#line 902 "cs.ATG"
+ string firstName = t.val;
if (la.kind == 14) {
- Get();
- Type(out secondType);
+ lexer.NextToken();
+ Type(
+#line 903 "cs.ATG"
+out secondType);
Identifier();
- secondName = t.val;
+
+#line 903 "cs.ATG"
+ secondName = t.val;
} else if (la.kind == 21) {
- } else SynErr(166);
- Location endPos = t.Location;
+ } else SynErr(165);
+
+#line 911 "cs.ATG"
+ Location endPos = t.Location;
Expect(21);
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 912 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(167);
+ lexer.NextToken();
+ } else SynErr(166);
+
+#line 914 "cs.ATG"
if (op == OverloadableOperatorType.Add && secondType == null)
op = OverloadableOperatorType.UnaryPlus;
if (op == OverloadableOperatorType.Subtract && secondType == null)
@@ -1289,45 +1983,77 @@ partial class Parser : AbstractParser
SafeAdd(operatorDeclaration, operatorDeclaration.Parameters, new ParameterDeclarationExpression(secondType, secondName));
}
compilationUnit.AddChild(operatorDeclaration);
+
+ } else if (
+#line 936 "cs.ATG"
+IsVarDecl()) {
- } else if (IsVarDecl()) {
+#line 937 "cs.ATG"
m.Check(Modifiers.Fields);
FieldDeclaration fd = new FieldDeclaration(attributes, type, m.Modifier);
fd.StartLocation = m.GetDeclarationLocation(startPos);
-
- if (m.Contains(Modifiers.Fixed)) {
- VariableDeclarator(fd);
+
+ if (
+#line 941 "cs.ATG"
+m.Contains(Modifiers.Fixed)) {
+ VariableDeclarator(
+#line 942 "cs.ATG"
+fd);
Expect(18);
- Expr(out expr);
+ Expr(
+#line 944 "cs.ATG"
+out expr);
+
+#line 944 "cs.ATG"
if (fd.Fields.Count > 0)
- fd.Fields[fd.Fields.Count-1].FixedArrayInitialization = expr;
+ fd.Fields[fd.Fields.Count-1].FixedArrayInitialization = expr;
Expect(19);
while (la.kind == 14) {
- Get();
- VariableDeclarator(fd);
+ lexer.NextToken();
+ VariableDeclarator(
+#line 948 "cs.ATG"
+fd);
Expect(18);
- Expr(out expr);
+ Expr(
+#line 950 "cs.ATG"
+out expr);
+
+#line 950 "cs.ATG"
if (fd.Fields.Count > 0)
- fd.Fields[fd.Fields.Count-1].FixedArrayInitialization = expr;
+ fd.Fields[fd.Fields.Count-1].FixedArrayInitialization = expr;
Expect(19);
}
- } else if (StartOf(9)) {
- VariableDeclarator(fd);
+ } else if (StartOf(18)) {
+ VariableDeclarator(
+#line 955 "cs.ATG"
+fd);
while (la.kind == 14) {
- Get();
- VariableDeclarator(fd);
+ lexer.NextToken();
+ VariableDeclarator(
+#line 956 "cs.ATG"
+fd);
}
- } else SynErr(168);
+ } else SynErr(167);
Expect(11);
- fd.EndLocation = t.EndLocation; compilationUnit.AddChild(fd);
+
+#line 958 "cs.ATG"
+ fd.EndLocation = t.EndLocation; compilationUnit.AddChild(fd);
} else if (la.kind == 111) {
- m.Check(Modifiers.Indexers);
- Get();
+
+#line 961 "cs.ATG"
+ m.Check(Modifiers.Indexers);
+ lexer.NextToken();
Expect(18);
- FormalParameterList(p);
+ FormalParameterList(
+#line 962 "cs.ATG"
+p);
Expect(19);
- Location endLocation = t.EndLocation;
+
+#line 962 "cs.ATG"
+ Location endLocation = t.EndLocation;
Expect(16);
+
+#line 963 "cs.ATG"
PropertyDeclaration indexer = new PropertyDeclaration(m.Modifier | Modifiers.Default, attributes, "Item", p);
indexer.StartLocation = startPos;
indexer.EndLocation = endLocation;
@@ -1335,40 +2061,66 @@ partial class Parser : AbstractParser
indexer.TypeReference = type;
PropertyGetRegion getRegion;
PropertySetRegion setRegion;
-
- AccessorDecls(out getRegion, out setRegion);
+
+ AccessorDecls(
+#line 971 "cs.ATG"
+out getRegion, out setRegion);
Expect(17);
+
+#line 972 "cs.ATG"
indexer.BodyEnd = t.EndLocation;
indexer.GetRegion = getRegion;
indexer.SetRegion = setRegion;
compilationUnit.AddChild(indexer);
-
- } else if (IsIdentifierToken(la)) {
- if (IsExplicitInterfaceImplementation()) {
- TypeName(out explicitInterface, false);
+
+ } else if (
+#line 977 "cs.ATG"
+IsIdentifierToken(la)) {
+ if (
+#line 978 "cs.ATG"
+IsExplicitInterfaceImplementation()) {
+ TypeName(
+#line 979 "cs.ATG"
+out explicitInterface, false);
+
+#line 980 "cs.ATG"
if (la.kind != Tokens.Dot || Peek(1).kind != Tokens.This) {
qualident = TypeReference.StripLastIdentifierFromType(ref explicitInterface);
- }
- } else if (StartOf(9)) {
+ }
+ } else if (StartOf(18)) {
Identifier();
- qualident = t.val;
- } else SynErr(169);
- Location qualIdentEndLocation = t.EndLocation;
+
+#line 983 "cs.ATG"
+ qualident = t.val;
+ } else SynErr(168);
+
+#line 985 "cs.ATG"
+ Location qualIdentEndLocation = t.EndLocation;
if (la.kind == 16 || la.kind == 20 || la.kind == 23) {
if (la.kind == 20 || la.kind == 23) {
- m.Check(Modifiers.PropertysEventsMethods);
+
+#line 989 "cs.ATG"
+ m.Check(Modifiers.PropertysEventsMethods);
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 991 "cs.ATG"
+templates);
}
Expect(20);
if (la.kind == 111) {
- Get();
- isExtensionMethod = true;
+ lexer.NextToken();
+
+#line 993 "cs.ATG"
+ isExtensionMethod = true;
}
- if (StartOf(12)) {
- FormalParameterList(p);
+ if (StartOf(11)) {
+ FormalParameterList(
+#line 994 "cs.ATG"
+p);
}
Expect(21);
+
+#line 996 "cs.ATG"
MethodDeclaration methodDeclaration = new MethodDeclaration {
Name = qualident,
Modifier = m.Modifier,
@@ -1383,18 +2135,26 @@ partial class Parser : AbstractParser
methodDeclaration.IsExtensionMethod = isExtensionMethod;
methodDeclaration.Templates = templates;
compilationUnit.AddChild(methodDeclaration);
-
+
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 1011 "cs.ATG"
+templates);
}
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 1012 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(170);
- methodDeclaration.Body = (BlockStatement)stmt;
+ lexer.NextToken();
+ } else SynErr(169);
+
+#line 1012 "cs.ATG"
+ methodDeclaration.Body = (BlockStatement)stmt;
} else {
- Get();
+ lexer.NextToken();
+
+#line 1015 "cs.ATG"
PropertyDeclaration pDecl = new PropertyDeclaration(qualident, type, m.Modifier, attributes);
if (explicitInterface != null)
pDecl.InterfaceImplementations.Add(new InterfaceImplementation(explicitInterface, qualident));
@@ -1403,22 +2163,32 @@ partial class Parser : AbstractParser
pDecl.BodyStart = t.Location;
PropertyGetRegion getRegion;
PropertySetRegion setRegion;
-
- AccessorDecls(out getRegion, out setRegion);
+
+ AccessorDecls(
+#line 1024 "cs.ATG"
+out getRegion, out setRegion);
Expect(17);
+
+#line 1026 "cs.ATG"
pDecl.GetRegion = getRegion;
pDecl.SetRegion = setRegion;
pDecl.BodyEnd = t.EndLocation;
compilationUnit.AddChild(pDecl);
-
+
}
} else if (la.kind == 15) {
- m.Check(Modifiers.Indexers);
- Get();
+
+#line 1034 "cs.ATG"
+ m.Check(Modifiers.Indexers);
+ lexer.NextToken();
Expect(111);
Expect(18);
- FormalParameterList(p);
+ FormalParameterList(
+#line 1035 "cs.ATG"
+p);
Expect(19);
+
+#line 1036 "cs.ATG"
PropertyDeclaration indexer = new PropertyDeclaration(m.Modifier | Modifiers.Default, attributes, "Item", p);
indexer.StartLocation = m.GetDeclarationLocation(startPos);
indexer.EndLocation = t.EndLocation;
@@ -1427,25 +2197,33 @@ partial class Parser : AbstractParser
SafeAdd(indexer, indexer.InterfaceImplementations, new InterfaceImplementation(explicitInterface, "this"));
PropertyGetRegion getRegion;
PropertySetRegion setRegion;
-
+
Expect(16);
- Location bodyStart = t.Location;
- AccessorDecls(out getRegion, out setRegion);
+
+#line 1045 "cs.ATG"
+ Location bodyStart = t.Location;
+ AccessorDecls(
+#line 1046 "cs.ATG"
+out getRegion, out setRegion);
Expect(17);
+
+#line 1047 "cs.ATG"
indexer.BodyStart = bodyStart;
indexer.BodyEnd = t.EndLocation;
indexer.GetRegion = getRegion;
indexer.SetRegion = setRegion;
compilationUnit.AddChild(indexer);
-
- } else SynErr(171);
- } else SynErr(172);
- } else SynErr(173);
+
+ } else SynErr(170);
+ } else SynErr(171);
+ } else SynErr(172);
}
void InterfaceMemberDecl() {
- TypeReference type;
+#line 1074 "cs.ATG"
+ TypeReference type;
+
AttributeSection section;
Modifiers mod = Modifiers.None;
List attributes = new List();
@@ -1455,968 +2233,1662 @@ partial class Parser : AbstractParser
PropertySetRegion setBlock;
Location startLocation = new Location(-1, -1);
List templates = new List();
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1087 "cs.ATG"
+out section);
+
+#line 1087 "cs.ATG"
+ attributes.Add(section);
}
if (la.kind == 89) {
- Get();
- mod = Modifiers.New; startLocation = t.Location;
+ lexer.NextToken();
+
+#line 1088 "cs.ATG"
+ mod = Modifiers.New; startLocation = t.Location;
}
- if (NotVoidPointer()) {
+ if (
+#line 1091 "cs.ATG"
+NotVoidPointer()) {
Expect(123);
- if (startLocation.IsEmpty) startLocation = t.Location;
+
+#line 1091 "cs.ATG"
+ if (startLocation.IsEmpty) startLocation = t.Location;
Identifier();
- name = t.val;
+
+#line 1092 "cs.ATG"
+ name = t.val;
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 1093 "cs.ATG"
+templates);
}
Expect(20);
- if (StartOf(12)) {
- FormalParameterList(parameters);
+ if (StartOf(11)) {
+ FormalParameterList(
+#line 1094 "cs.ATG"
+parameters);
}
Expect(21);
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 1095 "cs.ATG"
+templates);
}
Expect(11);
+
+#line 1097 "cs.ATG"
MethodDeclaration md = new MethodDeclaration {
Name = name, Modifier = mod, TypeReference = new TypeReference("System.Void", true),
Parameters = parameters, Attributes = attributes, Templates = templates,
StartLocation = startLocation, EndLocation = t.EndLocation
};
compilationUnit.AddChild(md);
-
+
} else if (StartOf(22)) {
- if (StartOf(11)) {
- Type(out type);
- if (startLocation.IsEmpty) startLocation = t.Location;
- if (StartOf(9)) {
+ if (StartOf(10)) {
+ Type(
+#line 1105 "cs.ATG"
+out type);
+
+#line 1105 "cs.ATG"
+ if (startLocation.IsEmpty) startLocation = t.Location;
+ if (StartOf(18)) {
Identifier();
- name = t.val; Location qualIdentEndLocation = t.EndLocation;
+
+#line 1107 "cs.ATG"
+ name = t.val; Location qualIdentEndLocation = t.EndLocation;
if (la.kind == 20 || la.kind == 23) {
if (la.kind == 23) {
- TypeParameterList(templates);
+ TypeParameterList(
+#line 1111 "cs.ATG"
+templates);
}
Expect(20);
- if (StartOf(12)) {
- FormalParameterList(parameters);
+ if (StartOf(11)) {
+ FormalParameterList(
+#line 1112 "cs.ATG"
+parameters);
}
Expect(21);
while (la.kind == 127) {
- TypeParameterConstraintsClause(templates);
+ TypeParameterConstraintsClause(
+#line 1114 "cs.ATG"
+templates);
}
Expect(11);
+
+#line 1115 "cs.ATG"
MethodDeclaration md = new MethodDeclaration {
Name = name, Modifier = mod, TypeReference = type,
Parameters = parameters, Attributes = attributes, Templates = templates,
StartLocation = startLocation, EndLocation = t.EndLocation
};
compilationUnit.AddChild(md);
-
+
} else if (la.kind == 16) {
+
+#line 1124 "cs.ATG"
PropertyDeclaration pd = new PropertyDeclaration(name, type, mod, attributes);
- compilationUnit.AddChild(pd);
- Get();
+ compilationUnit.AddChild(pd);
+ lexer.NextToken();
+
+#line 1127 "cs.ATG"
Location bodyStart = t.Location;
- InterfaceAccessors(out getBlock, out setBlock);
+ InterfaceAccessors(
+#line 1128 "cs.ATG"
+out getBlock, out setBlock);
Expect(17);
- pd.GetRegion = getBlock; pd.SetRegion = setBlock; pd.StartLocation = startLocation; pd.EndLocation = qualIdentEndLocation; pd.BodyStart = bodyStart; pd.BodyEnd = t.EndLocation;
- } else SynErr(174);
+
+#line 1129 "cs.ATG"
+ pd.GetRegion = getBlock; pd.SetRegion = setBlock; pd.StartLocation = startLocation; pd.EndLocation = qualIdentEndLocation; pd.BodyStart = bodyStart; pd.BodyEnd = t.EndLocation;
+ } else SynErr(173);
} else if (la.kind == 111) {
- Get();
+ lexer.NextToken();
Expect(18);
- FormalParameterList(parameters);
+ FormalParameterList(
+#line 1132 "cs.ATG"
+parameters);
Expect(19);
- Location bracketEndLocation = t.EndLocation;
+
+#line 1133 "cs.ATG"
+ Location bracketEndLocation = t.EndLocation;
+
+#line 1134 "cs.ATG"
PropertyDeclaration id = new PropertyDeclaration(mod | Modifiers.Default, attributes, "Item", parameters);
id.TypeReference = type;
- compilationUnit.AddChild(id);
+ compilationUnit.AddChild(id);
Expect(16);
+
+#line 1137 "cs.ATG"
Location bodyStart = t.Location;
- InterfaceAccessors(out getBlock, out setBlock);
+ InterfaceAccessors(
+#line 1138 "cs.ATG"
+out getBlock, out setBlock);
Expect(17);
+
+#line 1140 "cs.ATG"
id.GetRegion = getBlock; id.SetRegion = setBlock; id.StartLocation = startLocation; id.EndLocation = bracketEndLocation; id.BodyStart = bodyStart; id.BodyEnd = t.EndLocation;
- } else SynErr(175);
+ } else SynErr(174);
} else {
- Get();
- if (startLocation.IsEmpty) startLocation = t.Location;
- Type(out type);
+ lexer.NextToken();
+
+#line 1143 "cs.ATG"
+ if (startLocation.IsEmpty) startLocation = t.Location;
+ Type(
+#line 1144 "cs.ATG"
+out type);
Identifier();
+
+#line 1145 "cs.ATG"
EventDeclaration ed = new EventDeclaration {
TypeReference = type, Name = t.val, Modifier = mod, Attributes = attributes
};
compilationUnit.AddChild(ed);
-
+
Expect(11);
- ed.StartLocation = startLocation; ed.EndLocation = t.EndLocation;
+
+#line 1151 "cs.ATG"
+ ed.StartLocation = startLocation; ed.EndLocation = t.EndLocation;
}
- } else SynErr(176);
+ } else SynErr(175);
}
- void EnumMemberDecl(out FieldDeclaration f) {
+ void EnumMemberDecl(
+#line 1156 "cs.ATG"
+out FieldDeclaration f) {
+
+#line 1158 "cs.ATG"
Expression expr = null;
List attributes = new List();
AttributeSection section = null;
VariableDeclaration varDecl = null;
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1164 "cs.ATG"
+out section);
+
+#line 1164 "cs.ATG"
+ attributes.Add(section);
}
Identifier();
+
+#line 1165 "cs.ATG"
f = new FieldDeclaration(attributes);
varDecl = new VariableDeclaration(t.val);
f.Fields.Add(varDecl);
f.StartLocation = t.Location;
f.EndLocation = t.EndLocation;
-
+
if (la.kind == 3) {
- Get();
- Expr(out expr);
- varDecl.Initializer = expr;
+ lexer.NextToken();
+ Expr(
+#line 1171 "cs.ATG"
+out expr);
+
+#line 1171 "cs.ATG"
+ varDecl.Initializer = expr;
}
}
- void TypeWithRestriction(out TypeReference type, bool allowNullable, bool canBeUnbound) {
+ void TypeWithRestriction(
+#line 571 "cs.ATG"
+out TypeReference type, bool allowNullable, bool canBeUnbound) {
+
+#line 573 "cs.ATG"
Location startPos = la.Location;
string name;
int pointer = 0;
type = null;
-
+
if (StartOf(4)) {
- ClassType(out type, canBeUnbound);
+ ClassType(
+#line 579 "cs.ATG"
+out type, canBeUnbound);
} else if (StartOf(5)) {
- SimpleType(out name);
- type = new TypeReference(name, true);
+ SimpleType(
+#line 580 "cs.ATG"
+out name);
+
+#line 580 "cs.ATG"
+ type = new TypeReference(name, true);
} else if (la.kind == 123) {
- Get();
+ lexer.NextToken();
Expect(6);
- pointer = 1; type = new TypeReference("System.Void", true);
- } else SynErr(177);
- List r = new List();
- if (allowNullable && la.kind == Tokens.Question) {
- NullableQuestionMark(ref type);
- }
- while (IsPointerOrDims()) {
- int i = 0;
+
+#line 581 "cs.ATG"
+ pointer = 1; type = new TypeReference("System.Void", true);
+ } else SynErr(176);
+
+#line 582 "cs.ATG"
+ List r = new List();
+ if (
+#line 584 "cs.ATG"
+allowNullable && la.kind == Tokens.Question) {
+ NullableQuestionMark(
+#line 584 "cs.ATG"
+ref type);
+ }
+ while (
+#line 586 "cs.ATG"
+IsPointerOrDims()) {
+
+#line 586 "cs.ATG"
+ int i = 0;
if (la.kind == 6) {
- Get();
- ++pointer;
+ lexer.NextToken();
+
+#line 587 "cs.ATG"
+ ++pointer;
} else if (la.kind == 18) {
- Get();
+ lexer.NextToken();
while (la.kind == 14) {
- Get();
- ++i;
+ lexer.NextToken();
+
+#line 588 "cs.ATG"
+ ++i;
}
Expect(19);
- r.Add(i);
- } else SynErr(178);
+
+#line 588 "cs.ATG"
+ r.Add(i);
+ } else SynErr(177);
}
+
+#line 591 "cs.ATG"
if (type != null) {
type.RankSpecifier = r.ToArray();
type.PointerNestingLevel = pointer;
type.EndLocation = t.EndLocation;
type.StartLocation = startPos;
}
-
+
}
- void SimpleType(out string name) {
- name = String.Empty;
+ void SimpleType(
+#line 627 "cs.ATG"
+out string name) {
+
+#line 628 "cs.ATG"
+ name = String.Empty;
if (StartOf(23)) {
- IntegralType(out name);
+ IntegralType(
+#line 630 "cs.ATG"
+out name);
} else if (la.kind == 75) {
- Get();
- name = "System.Single";
+ lexer.NextToken();
+
+#line 631 "cs.ATG"
+ name = "System.Single";
} else if (la.kind == 66) {
- Get();
- name = "System.Double";
+ lexer.NextToken();
+
+#line 632 "cs.ATG"
+ name = "System.Double";
} else if (la.kind == 62) {
- Get();
- name = "System.Decimal";
+ lexer.NextToken();
+
+#line 633 "cs.ATG"
+ name = "System.Decimal";
} else if (la.kind == 52) {
- Get();
- name = "System.Boolean";
- } else SynErr(179);
+ lexer.NextToken();
+
+#line 634 "cs.ATG"
+ name = "System.Boolean";
+ } else SynErr(178);
}
- void NullableQuestionMark(ref TypeReference typeRef) {
- List typeArguments = new List(1);
+ void NullableQuestionMark(
+#line 2335 "cs.ATG"
+ref TypeReference typeRef) {
+
+#line 2336 "cs.ATG"
+ List typeArguments = new List(1);
Expect(12);
+
+#line 2340 "cs.ATG"
if (typeRef != null) typeArguments.Add(typeRef);
typeRef = new TypeReference("System.Nullable", typeArguments) { IsKeyword = true };
-
+
}
- void FixedParameter(out ParameterDeclarationExpression p) {
+ void FixedParameter(
+#line 657 "cs.ATG"
+out ParameterDeclarationExpression p) {
+
+#line 659 "cs.ATG"
TypeReference type;
ParameterModifiers mod = ParameterModifiers.In;
Location start = la.Location;
Expression expr;
-
+
if (la.kind == 93 || la.kind == 95 || la.kind == 100) {
if (la.kind == 100) {
- Get();
- mod = ParameterModifiers.Ref;
+ lexer.NextToken();
+
+#line 666 "cs.ATG"
+ mod = ParameterModifiers.Ref;
} else if (la.kind == 93) {
- Get();
- mod = ParameterModifiers.Out;
+ lexer.NextToken();
+
+#line 667 "cs.ATG"
+ mod = ParameterModifiers.Out;
} else {
- Get();
- mod = ParameterModifiers.Params;
+ lexer.NextToken();
+
+#line 668 "cs.ATG"
+ mod = ParameterModifiers.Params;
}
}
- Type(out type);
+ Type(
+#line 670 "cs.ATG"
+out type);
Identifier();
- p = new ParameterDeclarationExpression(type, t.val, mod);
+
+#line 671 "cs.ATG"
+ p = new ParameterDeclarationExpression(type, t.val, mod);
if (la.kind == 3) {
- Get();
- Expr(out expr);
- p.DefaultValue = expr; p.ParamModifier |= ParameterModifiers.Optional;
+ lexer.NextToken();
+ Expr(
+#line 672 "cs.ATG"
+out expr);
+
+#line 672 "cs.ATG"
+ p.DefaultValue = expr; p.ParamModifier |= ParameterModifiers.Optional;
}
- p.StartLocation = start; p.EndLocation = t.EndLocation;
+
+#line 673 "cs.ATG"
+ p.StartLocation = start; p.EndLocation = t.EndLocation;
}
- void AccessorModifiers(out ModifierList m) {
- m = new ModifierList();
+ void AccessorModifiers(
+#line 676 "cs.ATG"
+out ModifierList m) {
+
+#line 677 "cs.ATG"
+ m = new ModifierList();
if (la.kind == 96) {
- Get();
- m.Add(Modifiers.Private, t.Location);
+ lexer.NextToken();
+
+#line 679 "cs.ATG"
+ m.Add(Modifiers.Private, t.Location);
} else if (la.kind == 97) {
- Get();
- m.Add(Modifiers.Protected, t.Location);
+ lexer.NextToken();
+
+#line 680 "cs.ATG"
+ m.Add(Modifiers.Protected, t.Location);
if (la.kind == 84) {
- Get();
- m.Add(Modifiers.Internal, t.Location);
+ lexer.NextToken();
+
+#line 681 "cs.ATG"
+ m.Add(Modifiers.Internal, t.Location);
}
} else if (la.kind == 84) {
- Get();
- m.Add(Modifiers.Internal, t.Location);
+ lexer.NextToken();
+
+#line 682 "cs.ATG"
+ m.Add(Modifiers.Internal, t.Location);
if (la.kind == 97) {
- Get();
- m.Add(Modifiers.Protected, t.Location);
+ lexer.NextToken();
+
+#line 683 "cs.ATG"
+ m.Add(Modifiers.Protected, t.Location);
}
- } else SynErr(180);
+ } else SynErr(179);
}
- void Block(out Statement stmt) {
+ void Block(
+#line 1291 "cs.ATG"
+out Statement stmt) {
Expect(16);
+
+#line 1293 "cs.ATG"
BlockStatement blockStmt = new BlockStatement();
blockStmt.StartLocation = t.Location;
compilationUnit.BlockStart(blockStmt);
if (!ParseMethodBodies) lexer.SkipCurrentBlock(0);
-
+
while (StartOf(24)) {
Statement();
}
- while (!(la.kind == 0 || la.kind == 17)) {SynErr(181); Get();}
+ while (!(la.kind == 0 || la.kind == 17)) {SynErr(180); lexer.NextToken(); }
Expect(17);
+
+#line 1301 "cs.ATG"
stmt = blockStmt;
blockStmt.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
-
+
}
- void EventAccessorDecls(out EventAddRegion addBlock, out EventRemoveRegion removeBlock) {
+ void EventAccessorDecls(
+#line 1228 "cs.ATG"
+out EventAddRegion addBlock, out EventRemoveRegion removeBlock) {
+
+#line 1229 "cs.ATG"
AttributeSection section;
List attributes = new List();
Statement stmt;
addBlock = null;
removeBlock = null;
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1236 "cs.ATG"
+out section);
+
+#line 1236 "cs.ATG"
+ attributes.Add(section);
}
if (la.kind == 130) {
- addBlock = new EventAddRegion(attributes);
- AddAccessorDecl(out stmt);
- attributes = new List(); addBlock.Block = (BlockStatement)stmt;
+
+#line 1238 "cs.ATG"
+ addBlock = new EventAddRegion(attributes);
+ AddAccessorDecl(
+#line 1239 "cs.ATG"
+out stmt);
+
+#line 1239 "cs.ATG"
+ attributes = new List(); addBlock.Block = (BlockStatement)stmt;
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1240 "cs.ATG"
+out section);
+
+#line 1240 "cs.ATG"
+ attributes.Add(section);
}
- RemoveAccessorDecl(out stmt);
- removeBlock = new EventRemoveRegion(attributes); removeBlock.Block = (BlockStatement)stmt;
+ RemoveAccessorDecl(
+#line 1241 "cs.ATG"
+out stmt);
+
+#line 1241 "cs.ATG"
+ removeBlock = new EventRemoveRegion(attributes); removeBlock.Block = (BlockStatement)stmt;
} else if (la.kind == 131) {
- RemoveAccessorDecl(out stmt);
- removeBlock = new EventRemoveRegion(attributes); removeBlock.Block = (BlockStatement)stmt; attributes = new List();
+ RemoveAccessorDecl(
+#line 1243 "cs.ATG"
+out stmt);
+
+#line 1243 "cs.ATG"
+ removeBlock = new EventRemoveRegion(attributes); removeBlock.Block = (BlockStatement)stmt; attributes = new List();
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1244 "cs.ATG"
+out section);
+
+#line 1244 "cs.ATG"
+ attributes.Add(section);
}
- AddAccessorDecl(out stmt);
- addBlock = new EventAddRegion(attributes); addBlock.Block = (BlockStatement)stmt;
- } else SynErr(182);
+ AddAccessorDecl(
+#line 1245 "cs.ATG"
+out stmt);
+
+#line 1245 "cs.ATG"
+ addBlock = new EventAddRegion(attributes); addBlock.Block = (BlockStatement)stmt;
+ } else SynErr(181);
}
- void ConstructorInitializer(out ConstructorInitializer ci) {
- Expression expr; ci = new ConstructorInitializer();
+ void ConstructorInitializer(
+#line 1321 "cs.ATG"
+out ConstructorInitializer ci) {
+
+#line 1322 "cs.ATG"
+ Expression expr; ci = new ConstructorInitializer();
Expect(9);
if (la.kind == 51) {
- Get();
- ci.ConstructorInitializerType = ConstructorInitializerType.Base;
+ lexer.NextToken();
+
+#line 1326 "cs.ATG"
+ ci.ConstructorInitializerType = ConstructorInitializerType.Base;
} else if (la.kind == 111) {
- Get();
- ci.ConstructorInitializerType = ConstructorInitializerType.This;
- } else SynErr(183);
+ lexer.NextToken();
+
+#line 1327 "cs.ATG"
+ ci.ConstructorInitializerType = ConstructorInitializerType.This;
+ } else SynErr(182);
Expect(20);
if (StartOf(25)) {
- Argument(out expr);
- SafeAdd(ci, ci.Arguments, expr);
+ Argument(
+#line 1330 "cs.ATG"
+out expr);
+
+#line 1330 "cs.ATG"
+ SafeAdd(ci, ci.Arguments, expr);
while (la.kind == 14) {
- Get();
- Argument(out expr);
- SafeAdd(ci, ci.Arguments, expr);
+ lexer.NextToken();
+ Argument(
+#line 1331 "cs.ATG"
+out expr);
+
+#line 1331 "cs.ATG"
+ SafeAdd(ci, ci.Arguments, expr);
}
}
Expect(21);
}
- void OverloadableOperator(out OverloadableOperatorType op) {
- op = OverloadableOperatorType.None;
+ void OverloadableOperator(
+#line 1344 "cs.ATG"
+out OverloadableOperatorType op) {
+
+#line 1345 "cs.ATG"
+ op = OverloadableOperatorType.None;
switch (la.kind) {
case 4: {
- Get();
- op = OverloadableOperatorType.Add;
+ lexer.NextToken();
+
+#line 1347 "cs.ATG"
+ op = OverloadableOperatorType.Add;
break;
}
case 5: {
- Get();
- op = OverloadableOperatorType.Subtract;
+ lexer.NextToken();
+
+#line 1348 "cs.ATG"
+ op = OverloadableOperatorType.Subtract;
break;
}
case 24: {
- Get();
- op = OverloadableOperatorType.Not;
+ lexer.NextToken();
+
+#line 1350 "cs.ATG"
+ op = OverloadableOperatorType.Not;
break;
}
case 27: {
- Get();
- op = OverloadableOperatorType.BitNot;
+ lexer.NextToken();
+
+#line 1351 "cs.ATG"
+ op = OverloadableOperatorType.BitNot;
break;
}
case 31: {
- Get();
- op = OverloadableOperatorType.Increment;
+ lexer.NextToken();
+
+#line 1353 "cs.ATG"
+ op = OverloadableOperatorType.Increment;
break;
}
case 32: {
- Get();
- op = OverloadableOperatorType.Decrement;
+ lexer.NextToken();
+
+#line 1354 "cs.ATG"
+ op = OverloadableOperatorType.Decrement;
break;
}
case 113: {
- Get();
- op = OverloadableOperatorType.IsTrue;
+ lexer.NextToken();
+
+#line 1356 "cs.ATG"
+ op = OverloadableOperatorType.IsTrue;
break;
}
case 72: {
- Get();
- op = OverloadableOperatorType.IsFalse;
+ lexer.NextToken();
+
+#line 1357 "cs.ATG"
+ op = OverloadableOperatorType.IsFalse;
break;
}
case 6: {
- Get();
- op = OverloadableOperatorType.Multiply;
+ lexer.NextToken();
+
+#line 1359 "cs.ATG"
+ op = OverloadableOperatorType.Multiply;
break;
}
case 7: {
- Get();
- op = OverloadableOperatorType.Divide;
+ lexer.NextToken();
+
+#line 1360 "cs.ATG"
+ op = OverloadableOperatorType.Divide;
break;
}
case 8: {
- Get();
- op = OverloadableOperatorType.Modulus;
+ lexer.NextToken();
+
+#line 1361 "cs.ATG"
+ op = OverloadableOperatorType.Modulus;
break;
}
case 28: {
- Get();
- op = OverloadableOperatorType.BitwiseAnd;
+ lexer.NextToken();
+
+#line 1363 "cs.ATG"
+ op = OverloadableOperatorType.BitwiseAnd;
break;
}
case 29: {
- Get();
- op = OverloadableOperatorType.BitwiseOr;
+ lexer.NextToken();
+
+#line 1364 "cs.ATG"
+ op = OverloadableOperatorType.BitwiseOr;
break;
}
case 30: {
- Get();
- op = OverloadableOperatorType.ExclusiveOr;
+ lexer.NextToken();
+
+#line 1365 "cs.ATG"
+ op = OverloadableOperatorType.ExclusiveOr;
break;
}
case 37: {
- Get();
- op = OverloadableOperatorType.ShiftLeft;
+ lexer.NextToken();
+
+#line 1367 "cs.ATG"
+ op = OverloadableOperatorType.ShiftLeft;
break;
}
case 33: {
- Get();
- op = OverloadableOperatorType.Equality;
+ lexer.NextToken();
+
+#line 1368 "cs.ATG"
+ op = OverloadableOperatorType.Equality;
break;
}
case 34: {
- Get();
- op = OverloadableOperatorType.InEquality;
+ lexer.NextToken();
+
+#line 1369 "cs.ATG"
+ op = OverloadableOperatorType.InEquality;
break;
}
case 23: {
- Get();
- op = OverloadableOperatorType.LessThan;
+ lexer.NextToken();
+
+#line 1370 "cs.ATG"
+ op = OverloadableOperatorType.LessThan;
break;
}
case 35: {
- Get();
- op = OverloadableOperatorType.GreaterThanOrEqual;
+ lexer.NextToken();
+
+#line 1371 "cs.ATG"
+ op = OverloadableOperatorType.GreaterThanOrEqual;
break;
}
case 36: {
- Get();
- op = OverloadableOperatorType.LessThanOrEqual;
+ lexer.NextToken();
+
+#line 1372 "cs.ATG"
+ op = OverloadableOperatorType.LessThanOrEqual;
break;
}
case 22: {
- Get();
- op = OverloadableOperatorType.GreaterThan;
+ lexer.NextToken();
+
+#line 1373 "cs.ATG"
+ op = OverloadableOperatorType.GreaterThan;
if (la.kind == 22) {
- Get();
- op = OverloadableOperatorType.ShiftRight;
+ lexer.NextToken();
+
+#line 1373 "cs.ATG"
+ op = OverloadableOperatorType.ShiftRight;
}
break;
}
- default: SynErr(184); break;
+ default: SynErr(183); break;
}
}
- void VariableDeclarator(FieldDeclaration parentFieldDeclaration) {
- Expression expr = null;
+ void VariableDeclarator(
+#line 1283 "cs.ATG"
+FieldDeclaration parentFieldDeclaration) {
+
+#line 1284 "cs.ATG"
+ Expression expr = null;
Identifier();
- VariableDeclaration f = new VariableDeclaration(t.val); f.StartLocation = t.Location;
+
+#line 1286 "cs.ATG"
+ VariableDeclaration f = new VariableDeclaration(t.val); f.StartLocation = t.Location;
if (la.kind == 3) {
- Get();
- VariableInitializer(out expr);
- f.Initializer = expr;
+ lexer.NextToken();
+ VariableInitializer(
+#line 1287 "cs.ATG"
+out expr);
+
+#line 1287 "cs.ATG"
+ f.Initializer = expr;
}
- f.EndLocation = t.EndLocation; SafeAdd(parentFieldDeclaration, parentFieldDeclaration.Fields, f);
+
+#line 1288 "cs.ATG"
+ f.EndLocation = t.EndLocation; SafeAdd(parentFieldDeclaration, parentFieldDeclaration.Fields, f);
}
- void AccessorDecls(out PropertyGetRegion getBlock, out PropertySetRegion setBlock) {
+ void AccessorDecls(
+#line 1175 "cs.ATG"
+out PropertyGetRegion getBlock, out PropertySetRegion setBlock) {
+
+#line 1177 "cs.ATG"
List attributes = new List();
AttributeSection section;
getBlock = null;
setBlock = null;
ModifierList modifiers = null;
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1184 "cs.ATG"
+out section);
+
+#line 1184 "cs.ATG"
+ attributes.Add(section);
}
if (la.kind == 84 || la.kind == 96 || la.kind == 97) {
- AccessorModifiers(out modifiers);
+ AccessorModifiers(
+#line 1185 "cs.ATG"
+out modifiers);
}
if (la.kind == 128) {
- GetAccessorDecl(out getBlock, attributes);
- if (modifiers != null) {getBlock.Modifier = modifiers.Modifier; }
+ GetAccessorDecl(
+#line 1187 "cs.ATG"
+out getBlock, attributes);
+
+#line 1188 "cs.ATG"
+ if (modifiers != null) {getBlock.Modifier = modifiers.Modifier; }
if (StartOf(26)) {
- attributes = new List(); modifiers = null;
+
+#line 1189 "cs.ATG"
+ attributes = new List(); modifiers = null;
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1190 "cs.ATG"
+out section);
+
+#line 1190 "cs.ATG"
+ attributes.Add(section);
}
if (la.kind == 84 || la.kind == 96 || la.kind == 97) {
- AccessorModifiers(out modifiers);
+ AccessorModifiers(
+#line 1191 "cs.ATG"
+out modifiers);
}
- SetAccessorDecl(out setBlock, attributes);
- if (modifiers != null) {setBlock.Modifier = modifiers.Modifier; }
+ SetAccessorDecl(
+#line 1192 "cs.ATG"
+out setBlock, attributes);
+
+#line 1193 "cs.ATG"
+ if (modifiers != null) {setBlock.Modifier = modifiers.Modifier; }
}
} else if (la.kind == 129) {
- SetAccessorDecl(out setBlock, attributes);
- if (modifiers != null) {setBlock.Modifier = modifiers.Modifier; }
+ SetAccessorDecl(
+#line 1196 "cs.ATG"
+out setBlock, attributes);
+
+#line 1197 "cs.ATG"
+ if (modifiers != null) {setBlock.Modifier = modifiers.Modifier; }
if (StartOf(27)) {
- attributes = new List(); modifiers = null;
+
+#line 1198 "cs.ATG"
+ attributes = new List(); modifiers = null;
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1199 "cs.ATG"
+out section);
+
+#line 1199 "cs.ATG"
+ attributes.Add(section);
}
if (la.kind == 84 || la.kind == 96 || la.kind == 97) {
- AccessorModifiers(out modifiers);
+ AccessorModifiers(
+#line 1200 "cs.ATG"
+out modifiers);
}
- GetAccessorDecl(out getBlock, attributes);
- if (modifiers != null) {getBlock.Modifier = modifiers.Modifier; }
+ GetAccessorDecl(
+#line 1201 "cs.ATG"
+out getBlock, attributes);
+
+#line 1202 "cs.ATG"
+ if (modifiers != null) {getBlock.Modifier = modifiers.Modifier; }
}
- } else if (StartOf(9)) {
+ } else if (StartOf(18)) {
Identifier();
- Error("get or set accessor declaration expected");
- } else SynErr(185);
+
+#line 1204 "cs.ATG"
+ Error("get or set accessor declaration expected");
+ } else SynErr(184);
}
- void InterfaceAccessors(out PropertyGetRegion getBlock, out PropertySetRegion setBlock) {
+ void InterfaceAccessors(
+#line 1249 "cs.ATG"
+out PropertyGetRegion getBlock, out PropertySetRegion setBlock) {
+
+#line 1251 "cs.ATG"
AttributeSection section;
List attributes = new List();
getBlock = null; setBlock = null;
PropertyGetSetRegion lastBlock = null;
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1257 "cs.ATG"
+out section);
+
+#line 1257 "cs.ATG"
+ attributes.Add(section);
}
- Location startLocation = la.Location;
+
+#line 1258 "cs.ATG"
+ Location startLocation = la.Location;
if (la.kind == 128) {
- Get();
- getBlock = new PropertyGetRegion(null, attributes);
+ lexer.NextToken();
+
+#line 1260 "cs.ATG"
+ getBlock = new PropertyGetRegion(null, attributes);
} else if (la.kind == 129) {
- Get();
- setBlock = new PropertySetRegion(null, attributes);
- } else SynErr(186);
+ lexer.NextToken();
+
+#line 1261 "cs.ATG"
+ setBlock = new PropertySetRegion(null, attributes);
+ } else SynErr(185);
Expect(11);
+
+#line 1264 "cs.ATG"
if (getBlock != null) { getBlock.StartLocation = startLocation; getBlock.EndLocation = t.EndLocation; }
if (setBlock != null) { setBlock.StartLocation = startLocation; setBlock.EndLocation = t.EndLocation; }
- attributes = new List();
+ attributes = new List();
if (la.kind == 18 || la.kind == 128 || la.kind == 129) {
while (la.kind == 18) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1268 "cs.ATG"
+out section);
+
+#line 1268 "cs.ATG"
+ attributes.Add(section);
}
- startLocation = la.Location;
+
+#line 1269 "cs.ATG"
+ startLocation = la.Location;
if (la.kind == 128) {
- Get();
+ lexer.NextToken();
+
+#line 1271 "cs.ATG"
if (getBlock != null) Error("get already declared");
else { getBlock = new PropertyGetRegion(null, attributes); lastBlock = getBlock; }
-
+
} else if (la.kind == 129) {
- Get();
+ lexer.NextToken();
+
+#line 1274 "cs.ATG"
if (setBlock != null) Error("set already declared");
else { setBlock = new PropertySetRegion(null, attributes); lastBlock = setBlock; }
-
- } else SynErr(187);
+
+ } else SynErr(186);
Expect(11);
- if (lastBlock != null) { lastBlock.StartLocation = startLocation; lastBlock.EndLocation = t.EndLocation; }
+
+#line 1279 "cs.ATG"
+ if (lastBlock != null) { lastBlock.StartLocation = startLocation; lastBlock.EndLocation = t.EndLocation; }
}
}
- void GetAccessorDecl(out PropertyGetRegion getBlock, List attributes) {
- Statement stmt = null;
+ void GetAccessorDecl(
+#line 1208 "cs.ATG"
+out PropertyGetRegion getBlock, List attributes) {
+
+#line 1209 "cs.ATG"
+ Statement stmt = null;
Expect(128);
- Location startLocation = t.Location;
+
+#line 1212 "cs.ATG"
+ Location startLocation = t.Location;
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 1213 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(188);
- getBlock = new PropertyGetRegion((BlockStatement)stmt, attributes);
- getBlock.StartLocation = startLocation; getBlock.EndLocation = t.EndLocation;
+ lexer.NextToken();
+ } else SynErr(187);
+
+#line 1214 "cs.ATG"
+ getBlock = new PropertyGetRegion((BlockStatement)stmt, attributes);
+
+#line 1215 "cs.ATG"
+ getBlock.StartLocation = startLocation; getBlock.EndLocation = t.EndLocation;
}
- void SetAccessorDecl(out PropertySetRegion setBlock, List attributes) {
- Statement stmt = null;
+ void SetAccessorDecl(
+#line 1218 "cs.ATG"
+out PropertySetRegion setBlock, List attributes) {
+
+#line 1219 "cs.ATG"
+ Statement stmt = null;
Expect(129);
- Location startLocation = t.Location;
+
+#line 1222 "cs.ATG"
+ Location startLocation = t.Location;
if (la.kind == 16) {
- Block(out stmt);
+ Block(
+#line 1223 "cs.ATG"
+out stmt);
} else if (la.kind == 11) {
- Get();
- } else SynErr(189);
- setBlock = new PropertySetRegion((BlockStatement)stmt, attributes);
- setBlock.StartLocation = startLocation; setBlock.EndLocation = t.EndLocation;
+ lexer.NextToken();
+ } else SynErr(188);
+
+#line 1224 "cs.ATG"
+ setBlock = new PropertySetRegion((BlockStatement)stmt, attributes);
+
+#line 1225 "cs.ATG"
+ setBlock.StartLocation = startLocation; setBlock.EndLocation = t.EndLocation;
}
- void AddAccessorDecl(out Statement stmt) {
+ void AddAccessorDecl(
+#line 1307 "cs.ATG"
+out Statement stmt) {
+
+#line 1308 "cs.ATG"
stmt = null;
Expect(130);
- Block(out stmt);
+ Block(
+#line 1311 "cs.ATG"
+out stmt);
}
- void RemoveAccessorDecl(out Statement stmt) {
+ void RemoveAccessorDecl(
+#line 1314 "cs.ATG"
+out Statement stmt) {
+
+#line 1315 "cs.ATG"
stmt = null;
Expect(131);
- Block(out stmt);
+ Block(
+#line 1318 "cs.ATG"
+out stmt);
}
- void VariableInitializer(out Expression initializerExpression) {
- TypeReference type = null; Expression expr = null; initializerExpression = null;
+ void VariableInitializer(
+#line 1336 "cs.ATG"
+out Expression initializerExpression) {
+
+#line 1337 "cs.ATG"
+ TypeReference type = null; Expression expr = null; initializerExpression = null;
if (StartOf(6)) {
- Expr(out initializerExpression);
+ Expr(
+#line 1339 "cs.ATG"
+out initializerExpression);
} else if (la.kind == 16) {
- CollectionInitializer(out initializerExpression);
+ CollectionInitializer(
+#line 1340 "cs.ATG"
+out initializerExpression);
} else if (la.kind == 106) {
- Get();
- Type(out type);
+ lexer.NextToken();
+ Type(
+#line 1341 "cs.ATG"
+out type);
Expect(18);
- Expr(out expr);
+ Expr(
+#line 1341 "cs.ATG"
+out expr);
Expect(19);
- initializerExpression = new StackAllocExpression(type, expr);
- } else SynErr(190);
+
+#line 1341 "cs.ATG"
+ initializerExpression = new StackAllocExpression(type, expr);
+ } else SynErr(189);
}
void Statement() {
+
+#line 1498 "cs.ATG"
Statement stmt = null;
Location startPos = la.Location;
-
- while (!(StartOf(28))) {SynErr(191); Get();}
- if (IsLabel()) {
+
+ while (!(StartOf(28))) {SynErr(190); lexer.NextToken(); }
+ if (
+#line 1505 "cs.ATG"
+IsLabel()) {
Identifier();
- compilationUnit.AddChild(new LabelStatement(t.val));
+
+#line 1505 "cs.ATG"
+ compilationUnit.AddChild(new LabelStatement(t.val));
Expect(9);
Statement();
} else if (la.kind == 60) {
- Get();
- LocalVariableDecl(out stmt);
- if (stmt != null) { ((LocalVariableDeclaration)stmt).Modifier |= Modifiers.Const; }
+ lexer.NextToken();
+ LocalVariableDecl(
+#line 1509 "cs.ATG"
+out stmt);
+
+#line 1510 "cs.ATG"
+ if (stmt != null) { ((LocalVariableDeclaration)stmt).Modifier |= Modifiers.Const; }
Expect(11);
- compilationUnit.AddChild(stmt);
- } else if (IsLocalVarDecl()) {
- LocalVariableDecl(out stmt);
+
+#line 1511 "cs.ATG"
+ compilationUnit.AddChild(stmt);
+ } else if (
+#line 1513 "cs.ATG"
+IsLocalVarDecl()) {
+ LocalVariableDecl(
+#line 1513 "cs.ATG"
+out stmt);
Expect(11);
- compilationUnit.AddChild(stmt);
+
+#line 1513 "cs.ATG"
+ compilationUnit.AddChild(stmt);
} else if (StartOf(29)) {
- EmbeddedStatement(out stmt);
- compilationUnit.AddChild(stmt);
- } else SynErr(192);
+ EmbeddedStatement(
+#line 1515 "cs.ATG"
+out stmt);
+
+#line 1515 "cs.ATG"
+ compilationUnit.AddChild(stmt);
+ } else SynErr(191);
+
+#line 1521 "cs.ATG"
if (stmt != null) {
stmt.StartLocation = startPos;
stmt.EndLocation = t.EndLocation;
}
-
+
}
- void Argument(out Expression argumentexpr) {
- argumentexpr = null;
- if (IdentAndColon()) {
- Token ident; Expression expr;
+ void Argument(
+#line 1376 "cs.ATG"
+out Expression argumentexpr) {
+
+#line 1377 "cs.ATG"
+ argumentexpr = null;
+ if (
+#line 1379 "cs.ATG"
+IdentAndColon()) {
+
+#line 1380 "cs.ATG"
+ Token ident; Expression expr;
Identifier();
- ident = t;
+
+#line 1381 "cs.ATG"
+ ident = t;
Expect(9);
- ArgumentValue(out expr);
- argumentexpr = new NamedArgumentExpression(ident.val, expr) { StartLocation = ident.Location, EndLocation = t.EndLocation };
+ ArgumentValue(
+#line 1383 "cs.ATG"
+out expr);
+
+#line 1384 "cs.ATG"
+ argumentexpr = new NamedArgumentExpression(ident.val, expr) { StartLocation = ident.Location, EndLocation = t.EndLocation };
} else if (StartOf(25)) {
- ArgumentValue(out argumentexpr);
- } else SynErr(193);
+ ArgumentValue(
+#line 1386 "cs.ATG"
+out argumentexpr);
+ } else SynErr(192);
}
- void CollectionInitializer(out Expression outExpr) {
+ void CollectionInitializer(
+#line 1420 "cs.ATG"
+out Expression outExpr) {
+
+#line 1422 "cs.ATG"
Expression expr = null;
CollectionInitializerExpression initializer = new CollectionInitializerExpression();
-
+
Expect(16);
- initializer.StartLocation = t.Location;
+
+#line 1426 "cs.ATG"
+ initializer.StartLocation = t.Location;
if (StartOf(30)) {
- VariableInitializer(out expr);
- SafeAdd(initializer, initializer.CreateExpressions, expr);
- while (NotFinalComma()) {
+ VariableInitializer(
+#line 1427 "cs.ATG"
+out expr);
+
+#line 1428 "cs.ATG"
+ SafeAdd(initializer, initializer.CreateExpressions, expr);
+ while (
+#line 1429 "cs.ATG"
+NotFinalComma()) {
Expect(14);
- VariableInitializer(out expr);
- SafeAdd(initializer, initializer.CreateExpressions, expr);
+ VariableInitializer(
+#line 1430 "cs.ATG"
+out expr);
+
+#line 1431 "cs.ATG"
+ SafeAdd(initializer, initializer.CreateExpressions, expr);
}
if (la.kind == 14) {
- Get();
+ lexer.NextToken();
}
}
Expect(17);
- initializer.EndLocation = t.Location; outExpr = initializer;
+
+#line 1435 "cs.ATG"
+ initializer.EndLocation = t.Location; outExpr = initializer;
}
- void ArgumentValue(out Expression argumentexpr) {
+ void ArgumentValue(
+#line 1389 "cs.ATG"
+out Expression argumentexpr) {
+
+#line 1391 "cs.ATG"
Expression expr;
FieldDirection fd = FieldDirection.None;
-
+
if (la.kind == 93 || la.kind == 100) {
if (la.kind == 100) {
- Get();
- fd = FieldDirection.Ref;
+ lexer.NextToken();
+
+#line 1396 "cs.ATG"
+ fd = FieldDirection.Ref;
} else {
- Get();
- fd = FieldDirection.Out;
+ lexer.NextToken();
+
+#line 1397 "cs.ATG"
+ fd = FieldDirection.Out;
}
}
- Expr(out expr);
- argumentexpr = fd != FieldDirection.None ? argumentexpr = new DirectionExpression(fd, expr) : expr;
+ Expr(
+#line 1399 "cs.ATG"
+out expr);
+
+#line 1400 "cs.ATG"
+ argumentexpr = fd != FieldDirection.None ? argumentexpr = new DirectionExpression(fd, expr) : expr;
}
- void AssignmentOperator(out AssignmentOperatorType op) {
- op = AssignmentOperatorType.None;
+ void AssignmentOperator(
+#line 1403 "cs.ATG"
+out AssignmentOperatorType op) {
+
+#line 1404 "cs.ATG"
+ op = AssignmentOperatorType.None;
if (la.kind == 3) {
- Get();
- op = AssignmentOperatorType.Assign;
+ lexer.NextToken();
+
+#line 1406 "cs.ATG"
+ op = AssignmentOperatorType.Assign;
} else if (la.kind == 38) {
- Get();
- op = AssignmentOperatorType.Add;
+ lexer.NextToken();
+
+#line 1407 "cs.ATG"
+ op = AssignmentOperatorType.Add;
} else if (la.kind == 39) {
- Get();
- op = AssignmentOperatorType.Subtract;
+ lexer.NextToken();
+
+#line 1408 "cs.ATG"
+ op = AssignmentOperatorType.Subtract;
} else if (la.kind == 40) {
- Get();
- op = AssignmentOperatorType.Multiply;
+ lexer.NextToken();
+
+#line 1409 "cs.ATG"
+ op = AssignmentOperatorType.Multiply;
} else if (la.kind == 41) {
- Get();
- op = AssignmentOperatorType.Divide;
+ lexer.NextToken();
+
+#line 1410 "cs.ATG"
+ op = AssignmentOperatorType.Divide;
} else if (la.kind == 42) {
- Get();
- op = AssignmentOperatorType.Modulus;
+ lexer.NextToken();
+
+#line 1411 "cs.ATG"
+ op = AssignmentOperatorType.Modulus;
} else if (la.kind == 43) {
- Get();
- op = AssignmentOperatorType.BitwiseAnd;
+ lexer.NextToken();
+
+#line 1412 "cs.ATG"
+ op = AssignmentOperatorType.BitwiseAnd;
} else if (la.kind == 44) {
- Get();
- op = AssignmentOperatorType.BitwiseOr;
+ lexer.NextToken();
+
+#line 1413 "cs.ATG"
+ op = AssignmentOperatorType.BitwiseOr;
} else if (la.kind == 45) {
- Get();
- op = AssignmentOperatorType.ExclusiveOr;
+ lexer.NextToken();
+
+#line 1414 "cs.ATG"
+ op = AssignmentOperatorType.ExclusiveOr;
} else if (la.kind == 46) {
- Get();
- op = AssignmentOperatorType.ShiftLeft;
- } else if (la.kind == Tokens.GreaterThan && Peek(1).kind == Tokens.GreaterEqual) {
+ lexer.NextToken();
+
+#line 1415 "cs.ATG"
+ op = AssignmentOperatorType.ShiftLeft;
+ } else if (
+#line 1416 "cs.ATG"
+la.kind == Tokens.GreaterThan && Peek(1).kind == Tokens.GreaterEqual) {
Expect(22);
Expect(35);
- op = AssignmentOperatorType.ShiftRight;
- } else SynErr(194);
+
+#line 1417 "cs.ATG"
+ op = AssignmentOperatorType.ShiftRight;
+ } else SynErr(193);
}
- void CollectionOrObjectInitializer(out Expression outExpr) {
+ void CollectionOrObjectInitializer(
+#line 1438 "cs.ATG"
+out Expression outExpr) {
+
+#line 1440 "cs.ATG"
Expression expr = null;
CollectionInitializerExpression initializer = new CollectionInitializerExpression();
-
+
Expect(16);
- initializer.StartLocation = t.Location;
+
+#line 1444 "cs.ATG"
+ initializer.StartLocation = t.Location;
if (StartOf(30)) {
- ObjectPropertyInitializerOrVariableInitializer(out expr);
- SafeAdd(initializer, initializer.CreateExpressions, expr);
- while (NotFinalComma()) {
+ ObjectPropertyInitializerOrVariableInitializer(
+#line 1445 "cs.ATG"
+out expr);
+
+#line 1446 "cs.ATG"
+ SafeAdd(initializer, initializer.CreateExpressions, expr);
+ while (
+#line 1447 "cs.ATG"
+NotFinalComma()) {
Expect(14);
- ObjectPropertyInitializerOrVariableInitializer(out expr);
- SafeAdd(initializer, initializer.CreateExpressions, expr);
+ ObjectPropertyInitializerOrVariableInitializer(
+#line 1448 "cs.ATG"
+out expr);
+
+#line 1449 "cs.ATG"
+ SafeAdd(initializer, initializer.CreateExpressions, expr);
}
if (la.kind == 14) {
- Get();
+ lexer.NextToken();
}
}
Expect(17);
- initializer.EndLocation = t.Location; outExpr = initializer;
+
+#line 1453 "cs.ATG"
+ initializer.EndLocation = t.Location; outExpr = initializer;
}
- void ObjectPropertyInitializerOrVariableInitializer(out Expression expr) {
- expr = null;
- if (IdentAndAsgn()) {
+ void ObjectPropertyInitializerOrVariableInitializer(
+#line 1456 "cs.ATG"
+out Expression expr) {
+
+#line 1457 "cs.ATG"
+ expr = null;
+ if (
+#line 1459 "cs.ATG"
+IdentAndAsgn()) {
Identifier();
+
+#line 1461 "cs.ATG"
MemberInitializerExpression mie = new MemberInitializerExpression(t.val, null);
mie.StartLocation = t.Location;
mie.IsKey = true;
- Expression r = null;
+ Expression r = null;
Expect(3);
if (la.kind == 16) {
- CollectionOrObjectInitializer(out r);
+ CollectionOrObjectInitializer(
+#line 1466 "cs.ATG"
+out r);
} else if (StartOf(30)) {
- VariableInitializer(out r);
- } else SynErr(195);
- mie.Expression = r; mie.EndLocation = t.EndLocation; expr = mie;
+ VariableInitializer(
+#line 1467 "cs.ATG"
+out r);
+ } else SynErr(194);
+
+#line 1468 "cs.ATG"
+ mie.Expression = r; mie.EndLocation = t.EndLocation; expr = mie;
} else if (StartOf(30)) {
- VariableInitializer(out expr);
- } else SynErr(196);
+ VariableInitializer(
+#line 1470 "cs.ATG"
+out expr);
+ } else SynErr(195);
}
- void LocalVariableDecl(out Statement stmt) {
+ void LocalVariableDecl(
+#line 1474 "cs.ATG"
+out Statement stmt) {
+
+#line 1476 "cs.ATG"
TypeReference type;
VariableDeclaration var = null;
LocalVariableDeclaration localVariableDeclaration;
Location startPos = la.Location;
-
- Type(out type);
- localVariableDeclaration = new LocalVariableDeclaration(type); localVariableDeclaration.StartLocation = startPos;
- LocalVariableDeclarator(out var);
- SafeAdd(localVariableDeclaration, localVariableDeclaration.Variables, var);
+
+ Type(
+#line 1482 "cs.ATG"
+out type);
+
+#line 1482 "cs.ATG"
+ localVariableDeclaration = new LocalVariableDeclaration(type); localVariableDeclaration.StartLocation = startPos;
+ LocalVariableDeclarator(
+#line 1483 "cs.ATG"
+out var);
+
+#line 1483 "cs.ATG"
+ SafeAdd(localVariableDeclaration, localVariableDeclaration.Variables, var);
while (la.kind == 14) {
- Get();
- LocalVariableDeclarator(out var);
- SafeAdd(localVariableDeclaration, localVariableDeclaration.Variables, var);
+ lexer.NextToken();
+ LocalVariableDeclarator(
+#line 1484 "cs.ATG"
+out var);
+
+#line 1484 "cs.ATG"
+ SafeAdd(localVariableDeclaration, localVariableDeclaration.Variables, var);
}
- stmt = localVariableDeclaration; stmt.EndLocation = t.EndLocation;
+
+#line 1485 "cs.ATG"
+ stmt = localVariableDeclaration; stmt.EndLocation = t.EndLocation;
}
- void LocalVariableDeclarator(out VariableDeclaration var) {
- Expression expr = null;
+ void LocalVariableDeclarator(
+#line 1488 "cs.ATG"
+out VariableDeclaration var) {
+
+#line 1489 "cs.ATG"
+ Expression expr = null;
Identifier();
- var = new VariableDeclaration(t.val); var.StartLocation = t.Location;
+
+#line 1491 "cs.ATG"
+ var = new VariableDeclaration(t.val); var.StartLocation = t.Location;
if (la.kind == 3) {
- Get();
- VariableInitializer(out expr);
- var.Initializer = expr;
+ lexer.NextToken();
+ VariableInitializer(
+#line 1492 "cs.ATG"
+out expr);
+
+#line 1492 "cs.ATG"
+ var.Initializer = expr;
}
- var.EndLocation = t.EndLocation;
+
+#line 1493 "cs.ATG"
+ var.EndLocation = t.EndLocation;
}
- void EmbeddedStatement(out Statement statement) {
+ void EmbeddedStatement(
+#line 1528 "cs.ATG"
+out Statement statement) {
+
+#line 1530 "cs.ATG"
TypeReference type = null;
Expression expr = null;
Statement embeddedStatement = null;
statement = null;
+
- Location startLocation = la.Location;
+#line 1536 "cs.ATG"
+ Location startLocation = la.Location;
if (la.kind == 16) {
- Block(out statement);
+ Block(
+#line 1538 "cs.ATG"
+out statement);
} else if (la.kind == 11) {
- Get();
- statement = new EmptyStatement();
- } else if (UnCheckedAndLBrace()) {
- Statement block; bool isChecked = true;
+ lexer.NextToken();
+
+#line 1541 "cs.ATG"
+ statement = new EmptyStatement();
+ } else if (
+#line 1544 "cs.ATG"
+UnCheckedAndLBrace()) {
+
+#line 1544 "cs.ATG"
+ Statement block; bool isChecked = true;
if (la.kind == 58) {
- Get();
+ lexer.NextToken();
} else if (la.kind == 118) {
- Get();
+ lexer.NextToken();
+
+#line 1545 "cs.ATG"
isChecked = false;
- } else SynErr(197);
- Block(out block);
- statement = isChecked ? (Statement)new CheckedStatement(block) : (Statement)new UncheckedStatement(block);
+ } else SynErr(196);
+ Block(
+#line 1546 "cs.ATG"
+out block);
+
+#line 1546 "cs.ATG"
+ statement = isChecked ? (Statement)new CheckedStatement(block) : (Statement)new UncheckedStatement(block);
} else if (la.kind == 79) {
- IfStatement(out statement);
+ IfStatement(
+#line 1549 "cs.ATG"
+out statement);
} else if (la.kind == 110) {
- Get();
- List switchSections = new List();
+ lexer.NextToken();
+
+#line 1551 "cs.ATG"
+ List switchSections = new List();
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1552 "cs.ATG"
+out expr);
Expect(21);
Expect(16);
- SwitchSections(switchSections);
+ SwitchSections(
+#line 1553 "cs.ATG"
+switchSections);
Expect(17);
- statement = new SwitchStatement(expr, switchSections);
+
+#line 1555 "cs.ATG"
+ statement = new SwitchStatement(expr, switchSections);
} else if (la.kind == 125) {
- Get();
+ lexer.NextToken();
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1558 "cs.ATG"
+out expr);
Expect(21);
- EmbeddedStatement(out embeddedStatement);
+ EmbeddedStatement(
+#line 1559 "cs.ATG"
+out embeddedStatement);
+
+#line 1560 "cs.ATG"
statement = new DoLoopStatement(expr, embeddedStatement, ConditionType.While, ConditionPosition.Start);
} else if (la.kind == 65) {
- Get();
- EmbeddedStatement(out embeddedStatement);
+ lexer.NextToken();
+ EmbeddedStatement(
+#line 1562 "cs.ATG"
+out embeddedStatement);
Expect(125);
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1563 "cs.ATG"
+out expr);
Expect(21);
Expect(11);
- statement = new DoLoopStatement(expr, embeddedStatement, ConditionType.While, ConditionPosition.End);
+
+#line 1564 "cs.ATG"
+ statement = new DoLoopStatement(expr, embeddedStatement, ConditionType.While, ConditionPosition.End);
} else if (la.kind == 76) {
- Get();
- List initializer = null; List iterator = null;
+ lexer.NextToken();
+
+#line 1566 "cs.ATG"
+ List initializer = null; List iterator = null;
Expect(20);
if (StartOf(6)) {
- ForInitializer(out initializer);
+ ForInitializer(
+#line 1567 "cs.ATG"
+out initializer);
}
Expect(11);
if (StartOf(6)) {
- Expr(out expr);
+ Expr(
+#line 1568 "cs.ATG"
+out expr);
}
Expect(11);
if (StartOf(6)) {
- ForIterator(out iterator);
+ ForIterator(
+#line 1569 "cs.ATG"
+out iterator);
}
Expect(21);
- EmbeddedStatement(out embeddedStatement);
- statement = new ForStatement(initializer, expr, iterator, embeddedStatement);
+ EmbeddedStatement(
+#line 1570 "cs.ATG"
+out embeddedStatement);
+
+#line 1571 "cs.ATG"
+ statement = new ForStatement(initializer, expr, iterator, embeddedStatement);
} else if (la.kind == 77) {
- Get();
+ lexer.NextToken();
Expect(20);
- Type(out type);
+ Type(
+#line 1573 "cs.ATG"
+out type);
Identifier();
- string varName = t.val;
+
+#line 1573 "cs.ATG"
+ string varName = t.val;
Expect(81);
- Expr(out expr);
+ Expr(
+#line 1574 "cs.ATG"
+out expr);
Expect(21);
- EmbeddedStatement(out embeddedStatement);
- statement = new ForeachStatement(type, varName , expr, embeddedStatement);
+ EmbeddedStatement(
+#line 1575 "cs.ATG"
+out embeddedStatement);
+
+#line 1576 "cs.ATG"
+ statement = new ForeachStatement(type, varName , expr, embeddedStatement);
} else if (la.kind == 53) {
- Get();
+ lexer.NextToken();
Expect(11);
- statement = new BreakStatement();
+
+#line 1579 "cs.ATG"
+ statement = new BreakStatement();
} else if (la.kind == 61) {
- Get();
+ lexer.NextToken();
Expect(11);
- statement = new ContinueStatement();
+
+#line 1580 "cs.ATG"
+ statement = new ContinueStatement();
} else if (la.kind == 78) {
- GotoStatement(out statement);
- } else if (IsYieldStatement()) {
+ GotoStatement(
+#line 1581 "cs.ATG"
+out statement);
+ } else if (
+#line 1583 "cs.ATG"
+IsYieldStatement()) {
Expect(132);
if (la.kind == 101) {
- Get();
- Expr(out expr);
- statement = new YieldStatement(new ReturnStatement(expr));
+ lexer.NextToken();
+ Expr(
+#line 1584 "cs.ATG"
+out expr);
+
+#line 1584 "cs.ATG"
+ statement = new YieldStatement(new ReturnStatement(expr));
} else if (la.kind == 53) {
- Get();
- statement = new YieldStatement(new BreakStatement());
- } else SynErr(198);
+ lexer.NextToken();
+
+#line 1585 "cs.ATG"
+ statement = new YieldStatement(new BreakStatement());
+ } else SynErr(197);
Expect(11);
} else if (la.kind == 101) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- Expr(out expr);
+ Expr(
+#line 1588 "cs.ATG"
+out expr);
}
Expect(11);
- statement = new ReturnStatement(expr);
+
+#line 1588 "cs.ATG"
+ statement = new ReturnStatement(expr);
} else if (la.kind == 112) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- Expr(out expr);
+ Expr(
+#line 1589 "cs.ATG"
+out expr);
}
Expect(11);
- statement = new ThrowStatement(expr);
+
+#line 1589 "cs.ATG"
+ statement = new ThrowStatement(expr);
} else if (StartOf(6)) {
- StatementExpr(out statement);
- while (!(la.kind == 0 || la.kind == 11)) {SynErr(199); Get();}
+ StatementExpr(
+#line 1592 "cs.ATG"
+out statement);
+ while (!(la.kind == 0 || la.kind == 11)) {SynErr(198); lexer.NextToken(); }
Expect(11);
} else if (la.kind == 114) {
- TryStatement(out statement);
+ TryStatement(
+#line 1595 "cs.ATG"
+out statement);
} else if (la.kind == 86) {
- Get();
+ lexer.NextToken();
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1598 "cs.ATG"
+out expr);
Expect(21);
- EmbeddedStatement(out embeddedStatement);
- statement = new LockStatement(expr, embeddedStatement);
+ EmbeddedStatement(
+#line 1599 "cs.ATG"
+out embeddedStatement);
+
+#line 1599 "cs.ATG"
+ statement = new LockStatement(expr, embeddedStatement);
} else if (la.kind == 121) {
- Statement resourceAcquisitionStmt = null;
- Get();
+
+#line 1602 "cs.ATG"
+ Statement resourceAcquisitionStmt = null;
+ lexer.NextToken();
Expect(20);
- ResourceAcquisition(out resourceAcquisitionStmt);
+ ResourceAcquisition(
+#line 1604 "cs.ATG"
+out resourceAcquisitionStmt);
Expect(21);
- EmbeddedStatement(out embeddedStatement);
- statement = new UsingStatement(resourceAcquisitionStmt, embeddedStatement);
+ EmbeddedStatement(
+#line 1605 "cs.ATG"
+out embeddedStatement);
+
+#line 1605 "cs.ATG"
+ statement = new UsingStatement(resourceAcquisitionStmt, embeddedStatement);
} else if (la.kind == 119) {
- Get();
- Block(out embeddedStatement);
- statement = new UnsafeStatement(embeddedStatement);
+ lexer.NextToken();
+ Block(
+#line 1608 "cs.ATG"
+out embeddedStatement);
+
+#line 1608 "cs.ATG"
+ statement = new UnsafeStatement(embeddedStatement);
} else if (la.kind == 74) {
- Statement pointerDeclarationStmt = null;
- Get();
+
+#line 1610 "cs.ATG"
+ Statement pointerDeclarationStmt = null;
+ lexer.NextToken();
Expect(20);
- ResourceAcquisition(out pointerDeclarationStmt);
+ ResourceAcquisition(
+#line 1612 "cs.ATG"
+out pointerDeclarationStmt);
Expect(21);
- EmbeddedStatement(out embeddedStatement);
- statement = new FixedStatement(pointerDeclarationStmt, embeddedStatement);
- } else SynErr(200);
+ EmbeddedStatement(
+#line 1613 "cs.ATG"
+out embeddedStatement);
+
+#line 1613 "cs.ATG"
+ statement = new FixedStatement(pointerDeclarationStmt, embeddedStatement);
+ } else SynErr(199);
+
+#line 1615 "cs.ATG"
if (statement != null) {
statement.StartLocation = startLocation;
statement.EndLocation = t.EndLocation;
}
-
+
}
- void IfStatement(out Statement statement) {
+ void IfStatement(
+#line 1622 "cs.ATG"
+out Statement statement) {
+
+#line 1624 "cs.ATG"
Expression expr = null;
Statement embeddedStatement = null;
statement = null;
-
+
Expect(79);
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1630 "cs.ATG"
+out expr);
Expect(21);
- EmbeddedStatement(out embeddedStatement);
- Statement elseStatement = null;
+ EmbeddedStatement(
+#line 1631 "cs.ATG"
+out embeddedStatement);
+
+#line 1632 "cs.ATG"
+ Statement elseStatement = null;
if (la.kind == 67) {
- Get();
- EmbeddedStatement(out elseStatement);
+ lexer.NextToken();
+ EmbeddedStatement(
+#line 1633 "cs.ATG"
+out elseStatement);
}
- statement = elseStatement != null ? new IfElseStatement(expr, embeddedStatement, elseStatement) : new IfElseStatement(expr, embeddedStatement);
+
+#line 1634 "cs.ATG"
+ statement = elseStatement != null ? new IfElseStatement(expr, embeddedStatement, elseStatement) : new IfElseStatement(expr, embeddedStatement);
+
+#line 1635 "cs.ATG"
if (elseStatement is IfElseStatement && (elseStatement as IfElseStatement).TrueStatement.Count == 1) {
/* else if-section (otherwise we would have a BlockStatment) */
(statement as IfElseStatement).ElseIfSections.Add(
@@ -2425,19 +3897,33 @@ partial class Parser : AbstractParser
(statement as IfElseStatement).ElseIfSections.AddRange((elseStatement as IfElseStatement).ElseIfSections);
(statement as IfElseStatement).FalseStatement = (elseStatement as IfElseStatement).FalseStatement;
}
-
+
}
- void SwitchSections(List switchSections) {
+ void SwitchSections(
+#line 1665 "cs.ATG"
+List switchSections) {
+
+#line 1667 "cs.ATG"
SwitchSection switchSection = new SwitchSection();
CaseLabel label;
+
+ SwitchLabel(
+#line 1671 "cs.ATG"
+out label);
+
+#line 1671 "cs.ATG"
+ SafeAdd(switchSection, switchSection.SwitchLabels, label);
- SwitchLabel(out label);
- SafeAdd(switchSection, switchSection.SwitchLabels, label);
- compilationUnit.BlockStart(switchSection);
+#line 1672 "cs.ATG"
+ compilationUnit.BlockStart(switchSection);
while (StartOf(31)) {
if (la.kind == 55 || la.kind == 63) {
- SwitchLabel(out label);
+ SwitchLabel(
+#line 1674 "cs.ATG"
+out label);
+
+#line 1675 "cs.ATG"
if (label != null) {
if (switchSection.Children.Count > 0) {
// open new section
@@ -2447,188 +3933,326 @@ partial class Parser : AbstractParser
}
SafeAdd(switchSection, switchSection.SwitchLabels, label);
}
-
+
} else {
Statement();
}
}
- compilationUnit.BlockEnd(); switchSections.Add(switchSection);
+
+#line 1687 "cs.ATG"
+ compilationUnit.BlockEnd(); switchSections.Add(switchSection);
}
- void ForInitializer(out List initializer) {
+ void ForInitializer(
+#line 1646 "cs.ATG"
+out List initializer) {
+
+#line 1648 "cs.ATG"
Statement stmt;
initializer = new List();
-
- if (IsLocalVarDecl()) {
- LocalVariableDecl(out stmt);
+
+ if (
+#line 1652 "cs.ATG"
+IsLocalVarDecl()) {
+ LocalVariableDecl(
+#line 1652 "cs.ATG"
+out stmt);
+
+#line 1652 "cs.ATG"
initializer.Add(stmt);
} else if (StartOf(6)) {
- StatementExpr(out stmt);
+ StatementExpr(
+#line 1653 "cs.ATG"
+out stmt);
+
+#line 1653 "cs.ATG"
initializer.Add(stmt);
while (la.kind == 14) {
- Get();
- StatementExpr(out stmt);
+ lexer.NextToken();
+ StatementExpr(
+#line 1653 "cs.ATG"
+out stmt);
+
+#line 1653 "cs.ATG"
initializer.Add(stmt);
}
- } else SynErr(201);
+ } else SynErr(200);
}
- void ForIterator(out List iterator) {
+ void ForIterator(
+#line 1656 "cs.ATG"
+out List iterator) {
+
+#line 1658 "cs.ATG"
Statement stmt;
iterator = new List();
+
+ StatementExpr(
+#line 1662 "cs.ATG"
+out stmt);
- StatementExpr(out stmt);
+#line 1662 "cs.ATG"
iterator.Add(stmt);
while (la.kind == 14) {
- Get();
- StatementExpr(out stmt);
- iterator.Add(stmt);
+ lexer.NextToken();
+ StatementExpr(
+#line 1662 "cs.ATG"
+out stmt);
+
+#line 1662 "cs.ATG"
+ iterator.Add(stmt);
}
}
- void GotoStatement(out Statement stmt) {
- Expression expr; stmt = null;
+ void GotoStatement(
+#line 1744 "cs.ATG"
+out Statement stmt) {
+
+#line 1745 "cs.ATG"
+ Expression expr; stmt = null;
Expect(78);
- if (StartOf(9)) {
+ if (StartOf(18)) {
Identifier();
- stmt = new GotoStatement(t.val);
+
+#line 1749 "cs.ATG"
+ stmt = new GotoStatement(t.val);
Expect(11);
} else if (la.kind == 55) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 1750 "cs.ATG"
+out expr);
Expect(11);
- stmt = new GotoCaseStatement(expr);
+
+#line 1750 "cs.ATG"
+ stmt = new GotoCaseStatement(expr);
} else if (la.kind == 63) {
- Get();
+ lexer.NextToken();
Expect(11);
- stmt = new GotoCaseStatement(null);
- } else SynErr(202);
+
+#line 1751 "cs.ATG"
+ stmt = new GotoCaseStatement(null);
+ } else SynErr(201);
}
- void StatementExpr(out Statement stmt) {
- Expression expr;
- Expr(out expr);
- stmt = new ExpressionStatement(expr);
+ void StatementExpr(
+#line 1771 "cs.ATG"
+out Statement stmt) {
+
+#line 1772 "cs.ATG"
+ Expression expr;
+ Expr(
+#line 1774 "cs.ATG"
+out expr);
+
+#line 1777 "cs.ATG"
+ stmt = new ExpressionStatement(expr);
}
- void TryStatement(out Statement tryStatement) {
+ void TryStatement(
+#line 1697 "cs.ATG"
+out Statement tryStatement) {
+
+#line 1699 "cs.ATG"
Statement blockStmt = null, finallyStmt = null;
CatchClause catchClause = null;
List catchClauses = new List();
-
+
Expect(114);
- Block(out blockStmt);
+ Block(
+#line 1704 "cs.ATG"
+out blockStmt);
while (la.kind == 56) {
- CatchClause(out catchClause);
- if (catchClause != null) catchClauses.Add(catchClause);
+ CatchClause(
+#line 1706 "cs.ATG"
+out catchClause);
+
+#line 1707 "cs.ATG"
+ if (catchClause != null) catchClauses.Add(catchClause);
}
if (la.kind == 73) {
- Get();
- Block(out finallyStmt);
+ lexer.NextToken();
+ Block(
+#line 1709 "cs.ATG"
+out finallyStmt);
}
+
+#line 1711 "cs.ATG"
tryStatement = new TryCatchStatement(blockStmt, catchClauses, finallyStmt);
if (catchClauses != null) {
foreach (CatchClause cc in catchClauses) cc.Parent = tryStatement;
}
-
+
}
- void ResourceAcquisition(out Statement stmt) {
+ void ResourceAcquisition(
+#line 1755 "cs.ATG"
+out Statement stmt) {
+
+#line 1757 "cs.ATG"
stmt = null;
Expression expr;
-
- if (IsLocalVarDecl()) {
- LocalVariableDecl(out stmt);
+
+ if (
+#line 1762 "cs.ATG"
+IsLocalVarDecl()) {
+ LocalVariableDecl(
+#line 1762 "cs.ATG"
+out stmt);
} else if (StartOf(6)) {
- Expr(out expr);
- stmt = new ExpressionStatement(expr);
- } else SynErr(203);
+ Expr(
+#line 1763 "cs.ATG"
+out expr);
+
+#line 1767 "cs.ATG"
+ stmt = new ExpressionStatement(expr);
+ } else SynErr(202);
}
- void SwitchLabel(out CaseLabel label) {
- Expression expr = null; label = null;
+ void SwitchLabel(
+#line 1690 "cs.ATG"
+out CaseLabel label) {
+
+#line 1691 "cs.ATG"
+ Expression expr = null; label = null;
if (la.kind == 55) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 1693 "cs.ATG"
+out expr);
Expect(9);
- label = new CaseLabel(expr);
+
+#line 1693 "cs.ATG"
+ label = new CaseLabel(expr);
} else if (la.kind == 63) {
- Get();
+ lexer.NextToken();
Expect(9);
- label = new CaseLabel();
- } else SynErr(204);
+
+#line 1694 "cs.ATG"
+ label = new CaseLabel();
+ } else SynErr(203);
}
- void CatchClause(out CatchClause catchClause) {
+ void CatchClause(
+#line 1718 "cs.ATG"
+out CatchClause catchClause) {
Expect(56);
+
+#line 1720 "cs.ATG"
string identifier;
Statement stmt;
TypeReference typeRef;
Location startPos = t.Location;
catchClause = null;
-
+
if (la.kind == 16) {
- Block(out stmt);
- catchClause = new CatchClause(stmt);
+ Block(
+#line 1728 "cs.ATG"
+out stmt);
+
+#line 1728 "cs.ATG"
+ catchClause = new CatchClause(stmt);
} else if (la.kind == 20) {
- Get();
- ClassType(out typeRef, false);
- identifier = null;
- if (StartOf(9)) {
+ lexer.NextToken();
+ ClassType(
+#line 1731 "cs.ATG"
+out typeRef, false);
+
+#line 1731 "cs.ATG"
+ identifier = null;
+ if (StartOf(18)) {
Identifier();
- identifier = t.val;
+
+#line 1732 "cs.ATG"
+ identifier = t.val;
}
Expect(21);
- Block(out stmt);
- catchClause = new CatchClause(typeRef, identifier, stmt);
- } else SynErr(205);
+ Block(
+#line 1733 "cs.ATG"
+out stmt);
+
+#line 1734 "cs.ATG"
+ catchClause = new CatchClause(typeRef, identifier, stmt);
+ } else SynErr(204);
+
+#line 1737 "cs.ATG"
if (catchClause != null) {
catchClause.StartLocation = startPos;
catchClause.EndLocation = t.Location;
}
-
+
}
- void UnaryExpr(out Expression uExpr) {
+ void UnaryExpr(
+#line 1806 "cs.ATG"
+out Expression uExpr) {
+
+#line 1808 "cs.ATG"
TypeReference type = null;
Expression expr = null;
ArrayList expressions = new ArrayList();
uExpr = null;
-
- while (StartOf(32)) {
+
+ while (StartOf(32) ||
+#line 1830 "cs.ATG"
+IsTypeCast()) {
if (la.kind == 4) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Plus));
+ lexer.NextToken();
+
+#line 1817 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Plus));
} else if (la.kind == 5) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Minus));
+ lexer.NextToken();
+
+#line 1818 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Minus));
} else if (la.kind == 24) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Not));
+ lexer.NextToken();
+
+#line 1819 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Not));
} else if (la.kind == 27) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.BitNot));
+ lexer.NextToken();
+
+#line 1820 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.BitNot));
} else if (la.kind == 6) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Dereference));
+ lexer.NextToken();
+
+#line 1821 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Dereference));
} else if (la.kind == 31) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Increment));
+ lexer.NextToken();
+
+#line 1822 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Increment));
} else if (la.kind == 32) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Decrement));
+ lexer.NextToken();
+
+#line 1823 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.Decrement));
} else if (la.kind == 28) {
- Get();
- expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.AddressOf));
+ lexer.NextToken();
+
+#line 1824 "cs.ATG"
+ expressions.Add(new UnaryOperatorExpression(UnaryOperatorType.AddressOf));
} else {
Expect(20);
- Type(out type);
+ Type(
+#line 1830 "cs.ATG"
+out type);
Expect(21);
- expressions.Add(new CastExpression(type));
+
+#line 1830 "cs.ATG"
+ expressions.Add(new CastExpression(type));
}
}
- if (LastExpressionIsUnaryMinus(expressions) && IsMostNegativeIntegerWithoutTypeSuffix()) {
+ if (
+#line 1835 "cs.ATG"
+LastExpressionIsUnaryMinus(expressions) && IsMostNegativeIntegerWithoutTypeSuffix()) {
Expect(2);
+
+#line 1838 "cs.ATG"
expressions.RemoveAt(expressions.Count - 1);
if (t.literalValue is uint) {
expr = new PrimitiveExpression(int.MinValue, int.MinValue.ToString());
@@ -2637,10 +4261,14 @@ partial class Parser : AbstractParser
} else {
throw new Exception("t.literalValue must be uint or ulong");
}
-
+
} else if (StartOf(33)) {
- PrimaryExpr(out expr);
- } else SynErr(206);
+ PrimaryExpr(
+#line 1847 "cs.ATG"
+out expr);
+ } else SynErr(205);
+
+#line 1849 "cs.ATG"
for (int i = 0; i < expressions.Count; ++i) {
Expression nextExpression = i + 1 < expressions.Count ? (Expression)expressions[i + 1] : expr;
if (expressions[i] is CastExpression) {
@@ -2654,876 +4282,1574 @@ partial class Parser : AbstractParser
} else {
uExpr = expr;
}
-
+
}
- void ConditionalOrExpr(ref Expression outExpr) {
- Expression expr;
- ConditionalAndExpr(ref outExpr);
+ void ConditionalOrExpr(
+#line 2173 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2174 "cs.ATG"
+ Expression expr;
+ ConditionalAndExpr(
+#line 2176 "cs.ATG"
+ref outExpr);
while (la.kind == 26) {
- Get();
- UnaryExpr(out expr);
- ConditionalAndExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.LogicalOr, expr);
+ lexer.NextToken();
+ UnaryExpr(
+#line 2176 "cs.ATG"
+out expr);
+ ConditionalAndExpr(
+#line 2176 "cs.ATG"
+ref expr);
+
+#line 2176 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.LogicalOr, expr);
}
}
- void PrimaryExpr(out Expression pexpr) {
+ void PrimaryExpr(
+#line 1866 "cs.ATG"
+out Expression pexpr) {
+
+#line 1868 "cs.ATG"
TypeReference type = null;
Expression expr;
pexpr = null;
+
- Location startLocation = la.Location;
+#line 1873 "cs.ATG"
+ Location startLocation = la.Location;
if (la.kind == 113) {
- Get();
- pexpr = new PrimitiveExpression(true, "true");
+ lexer.NextToken();
+
+#line 1875 "cs.ATG"
+ pexpr = new PrimitiveExpression(true, "true");
} else if (la.kind == 72) {
- Get();
- pexpr = new PrimitiveExpression(false, "false");
+ lexer.NextToken();
+
+#line 1876 "cs.ATG"
+ pexpr = new PrimitiveExpression(false, "false");
} else if (la.kind == 90) {
- Get();
- pexpr = new PrimitiveExpression(null, "null");
+ lexer.NextToken();
+
+#line 1877 "cs.ATG"
+ pexpr = new PrimitiveExpression(null, "null");
} else if (la.kind == 2) {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
- } else if (StartOfQueryExpression()) {
- QueryExpression(out pexpr);
- } else if (IdentAndDoubleColon()) {
+ lexer.NextToken();
+
+#line 1878 "cs.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ } else if (
+#line 1879 "cs.ATG"
+StartOfQueryExpression()) {
+ QueryExpression(
+#line 1880 "cs.ATG"
+out pexpr);
+ } else if (
+#line 1881 "cs.ATG"
+IdentAndDoubleColon()) {
Identifier();
- type = new TypeReference(t.val);
+
+#line 1882 "cs.ATG"
+ type = new TypeReference(t.val);
Expect(10);
- pexpr = new TypeReferenceExpression(type);
+
+#line 1883 "cs.ATG"
+ pexpr = new TypeReferenceExpression(type);
Identifier();
- if (type.Type == "global") { type.IsGlobal = true; type.Type = t.val ?? "?"; } else type.Type += "." + (t.val ?? "?");
- } else if (StartOf(9)) {
+
+#line 1884 "cs.ATG"
+ if (type.Type == "global") { type.IsGlobal = true; type.Type = t.val ?? "?"; } else type.Type += "." + (t.val ?? "?");
+ } else if (StartOf(18)) {
Identifier();
- pexpr = new IdentifierExpression(t.val);
- if (la.kind == 23 || la.kind == 48) {
+
+#line 1888 "cs.ATG"
+ pexpr = new IdentifierExpression(t.val);
+ if (la.kind == 48 ||
+#line 1891 "cs.ATG"
+IsGenericInSimpleNameOrMemberAccess()) {
if (la.kind == 48) {
- ShortedLambdaExpression((IdentifierExpression)pexpr, out pexpr);
+ ShortedLambdaExpression(
+#line 1890 "cs.ATG"
+(IdentifierExpression)pexpr, out pexpr);
} else {
- List typeList;
- TypeArgumentList(out typeList, false);
- ((IdentifierExpression)pexpr).TypeArguments = typeList;
+
+#line 1892 "cs.ATG"
+ List typeList;
+ TypeArgumentList(
+#line 1893 "cs.ATG"
+out typeList, false);
+
+#line 1894 "cs.ATG"
+ ((IdentifierExpression)pexpr).TypeArguments = typeList;
}
}
- } else if (IsLambdaExpression()) {
- LambdaExpression(out pexpr);
+ } else if (
+#line 1896 "cs.ATG"
+IsLambdaExpression()) {
+ LambdaExpression(
+#line 1897 "cs.ATG"
+out pexpr);
} else if (la.kind == 20) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 1900 "cs.ATG"
+out expr);
Expect(21);
- pexpr = new ParenthesizedExpression(expr);
+
+#line 1900 "cs.ATG"
+ pexpr = new ParenthesizedExpression(expr);
} else if (StartOf(34)) {
- string val = null;
+
+#line 1903 "cs.ATG"
+ string val = null;
switch (la.kind) {
case 52: {
- Get();
- val = "System.Boolean";
+ lexer.NextToken();
+
+#line 1904 "cs.ATG"
+ val = "System.Boolean";
break;
}
case 54: {
- Get();
- val = "System.Byte";
+ lexer.NextToken();
+
+#line 1905 "cs.ATG"
+ val = "System.Byte";
break;
}
case 57: {
- Get();
- val = "System.Char";
+ lexer.NextToken();
+
+#line 1906 "cs.ATG"
+ val = "System.Char";
break;
}
case 62: {
- Get();
- val = "System.Decimal";
+ lexer.NextToken();
+
+#line 1907 "cs.ATG"
+ val = "System.Decimal";
break;
}
case 66: {
- Get();
- val = "System.Double";
+ lexer.NextToken();
+
+#line 1908 "cs.ATG"
+ val = "System.Double";
break;
}
case 75: {
- Get();
- val = "System.Single";
+ lexer.NextToken();
+
+#line 1909 "cs.ATG"
+ val = "System.Single";
break;
}
case 82: {
- Get();
- val = "System.Int32";
+ lexer.NextToken();
+
+#line 1910 "cs.ATG"
+ val = "System.Int32";
break;
}
case 87: {
- Get();
- val = "System.Int64";
+ lexer.NextToken();
+
+#line 1911 "cs.ATG"
+ val = "System.Int64";
break;
}
case 91: {
- Get();
- val = "System.Object";
+ lexer.NextToken();
+
+#line 1912 "cs.ATG"
+ val = "System.Object";
break;
}
case 102: {
- Get();
- val = "System.SByte";
+ lexer.NextToken();
+
+#line 1913 "cs.ATG"
+ val = "System.SByte";
break;
}
case 104: {
- Get();
- val = "System.Int16";
+ lexer.NextToken();
+
+#line 1914 "cs.ATG"
+ val = "System.Int16";
break;
}
case 108: {
- Get();
- val = "System.String";
+ lexer.NextToken();
+
+#line 1915 "cs.ATG"
+ val = "System.String";
break;
}
case 116: {
- Get();
- val = "System.UInt32";
+ lexer.NextToken();
+
+#line 1916 "cs.ATG"
+ val = "System.UInt32";
break;
}
case 117: {
- Get();
- val = "System.UInt64";
+ lexer.NextToken();
+
+#line 1917 "cs.ATG"
+ val = "System.UInt64";
break;
}
case 120: {
- Get();
- val = "System.UInt16";
+ lexer.NextToken();
+
+#line 1918 "cs.ATG"
+ val = "System.UInt16";
break;
}
case 123: {
- Get();
- val = "System.Void";
+ lexer.NextToken();
+
+#line 1919 "cs.ATG"
+ val = "System.Void";
break;
}
}
- pexpr = new TypeReferenceExpression(new TypeReference(val, true)) { StartLocation = t.Location, EndLocation = t.EndLocation };
+
+#line 1921 "cs.ATG"
+ pexpr = new TypeReferenceExpression(new TypeReference(val, true)) { StartLocation = t.Location, EndLocation = t.EndLocation };
} else if (la.kind == 111) {
- Get();
- pexpr = new ThisReferenceExpression(); pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
+ lexer.NextToken();
+
+#line 1924 "cs.ATG"
+ pexpr = new ThisReferenceExpression(); pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
} else if (la.kind == 51) {
- Get();
- pexpr = new BaseReferenceExpression(); pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
+ lexer.NextToken();
+
+#line 1926 "cs.ATG"
+ pexpr = new BaseReferenceExpression(); pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
} else if (la.kind == 89) {
- NewExpression(out pexpr);
+ NewExpression(
+#line 1929 "cs.ATG"
+out pexpr);
} else if (la.kind == 115) {
- Get();
+ lexer.NextToken();
Expect(20);
- if (NotVoidPointer()) {
+ if (
+#line 1933 "cs.ATG"
+NotVoidPointer()) {
Expect(123);
- type = new TypeReference("System.Void", true);
- } else if (StartOf(11)) {
- TypeWithRestriction(out type, true, true);
- } else SynErr(207);
+
+#line 1933 "cs.ATG"
+ type = new TypeReference("System.Void", true);
+ } else if (StartOf(10)) {
+ TypeWithRestriction(
+#line 1934 "cs.ATG"
+out type, true, true);
+ } else SynErr(206);
Expect(21);
- pexpr = new TypeOfExpression(type);
+
+#line 1936 "cs.ATG"
+ pexpr = new TypeOfExpression(type);
} else if (la.kind == 63) {
- Get();
+ lexer.NextToken();
Expect(20);
- Type(out type);
+ Type(
+#line 1938 "cs.ATG"
+out type);
Expect(21);
- pexpr = new DefaultValueExpression(type);
+
+#line 1938 "cs.ATG"
+ pexpr = new DefaultValueExpression(type);
} else if (la.kind == 105) {
- Get();
+ lexer.NextToken();
Expect(20);
- Type(out type);
+ Type(
+#line 1939 "cs.ATG"
+out type);
Expect(21);
- pexpr = new SizeOfExpression(type);
+
+#line 1939 "cs.ATG"
+ pexpr = new SizeOfExpression(type);
} else if (la.kind == 58) {
- Get();
+ lexer.NextToken();
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1940 "cs.ATG"
+out expr);
Expect(21);
- pexpr = new CheckedExpression(expr);
+
+#line 1940 "cs.ATG"
+ pexpr = new CheckedExpression(expr);
} else if (la.kind == 118) {
- Get();
+ lexer.NextToken();
Expect(20);
- Expr(out expr);
+ Expr(
+#line 1941 "cs.ATG"
+out expr);
Expect(21);
- pexpr = new UncheckedExpression(expr);
+
+#line 1941 "cs.ATG"
+ pexpr = new UncheckedExpression(expr);
} else if (la.kind == 64) {
- Get();
- AnonymousMethodExpr(out expr);
- pexpr = expr;
- } else SynErr(208);
+ lexer.NextToken();
+ AnonymousMethodExpr(
+#line 1942 "cs.ATG"
+out expr);
+
+#line 1942 "cs.ATG"
+ pexpr = expr;
+ } else SynErr(207);
+
+#line 1944 "cs.ATG"
if (pexpr != null) {
if (pexpr.StartLocation.IsEmpty)
pexpr.StartLocation = startLocation;
if (pexpr.EndLocation.IsEmpty)
pexpr.EndLocation = t.EndLocation;
}
-
+
while (StartOf(35)) {
- startLocation = la.Location;
+
+#line 1952 "cs.ATG"
+ startLocation = la.Location;
switch (la.kind) {
case 31: {
- Get();
- pexpr = new UnaryOperatorExpression(pexpr, UnaryOperatorType.PostIncrement);
+ lexer.NextToken();
+
+#line 1954 "cs.ATG"
+ pexpr = new UnaryOperatorExpression(pexpr, UnaryOperatorType.PostIncrement);
break;
}
case 32: {
- Get();
- pexpr = new UnaryOperatorExpression(pexpr, UnaryOperatorType.PostDecrement);
+ lexer.NextToken();
+
+#line 1956 "cs.ATG"
+ pexpr = new UnaryOperatorExpression(pexpr, UnaryOperatorType.PostDecrement);
break;
}
case 47: {
- PointerMemberAccess(out pexpr, pexpr);
+ PointerMemberAccess(
+#line 1958 "cs.ATG"
+out pexpr, pexpr);
break;
}
case 15: {
- MemberAccess(out pexpr, pexpr);
+ MemberAccess(
+#line 1959 "cs.ATG"
+out pexpr, pexpr);
break;
}
case 20: {
- Get();
- List parameters = new List();
- pexpr = new InvocationExpression(pexpr, parameters);
+ lexer.NextToken();
+
+#line 1963 "cs.ATG"
+ List parameters = new List();
+
+#line 1964 "cs.ATG"
+ pexpr = new InvocationExpression(pexpr, parameters);
if (StartOf(25)) {
- Argument(out expr);
- SafeAdd(pexpr, parameters, expr);
+ Argument(
+#line 1965 "cs.ATG"
+out expr);
+
+#line 1965 "cs.ATG"
+ SafeAdd(pexpr, parameters, expr);
while (la.kind == 14) {
- Get();
- Argument(out expr);
- SafeAdd(pexpr, parameters, expr);
+ lexer.NextToken();
+ Argument(
+#line 1966 "cs.ATG"
+out expr);
+
+#line 1966 "cs.ATG"
+ SafeAdd(pexpr, parameters, expr);
}
}
Expect(21);
break;
}
case 18: {
+
+#line 1972 "cs.ATG"
List indices = new List();
pexpr = new IndexerExpression(pexpr, indices);
-
- Get();
- Expr(out expr);
- SafeAdd(pexpr, indices, expr);
+
+ lexer.NextToken();
+ Expr(
+#line 1975 "cs.ATG"
+out expr);
+
+#line 1975 "cs.ATG"
+ SafeAdd(pexpr, indices, expr);
while (la.kind == 14) {
- Get();
- Expr(out expr);
- SafeAdd(pexpr, indices, expr);
+ lexer.NextToken();
+ Expr(
+#line 1976 "cs.ATG"
+out expr);
+
+#line 1976 "cs.ATG"
+ SafeAdd(pexpr, indices, expr);
}
Expect(19);
break;
}
}
+
+#line 1979 "cs.ATG"
if (pexpr != null) {
if (pexpr.StartLocation.IsEmpty)
pexpr.StartLocation = startLocation;
if (pexpr.EndLocation.IsEmpty)
pexpr.EndLocation = t.EndLocation;
}
-
+
}
}
- void QueryExpression(out Expression outExpr) {
+ void QueryExpression(
+#line 2426 "cs.ATG"
+out Expression outExpr) {
+
+#line 2427 "cs.ATG"
QueryExpression q = new QueryExpression(); outExpr = q; q.StartLocation = la.Location;
QueryExpressionFromClause fromClause;
-
- QueryExpressionFromClause(out fromClause);
- q.FromClause = fromClause;
- QueryExpressionBody(ref q);
+
+ QueryExpressionFromClause(
+#line 2431 "cs.ATG"
+out fromClause);
+
+#line 2431 "cs.ATG"
+ q.FromClause = fromClause;
+ QueryExpressionBody(
+#line 2432 "cs.ATG"
+ref q);
+
+#line 2433 "cs.ATG"
q.EndLocation = t.EndLocation;
outExpr = q; /* set outExpr to q again if QueryExpressionBody changed it (can happen with 'into' clauses) */
-
+
}
- void ShortedLambdaExpression(IdentifierExpression ident, out Expression pexpr) {
- LambdaExpression lambda = new LambdaExpression(); pexpr = lambda;
+ void ShortedLambdaExpression(
+#line 2093 "cs.ATG"
+IdentifierExpression ident, out Expression pexpr) {
+
+#line 2094 "cs.ATG"
+ LambdaExpression lambda = new LambdaExpression(); pexpr = lambda;
Expect(48);
+
+#line 2099 "cs.ATG"
lambda.StartLocation = ident.StartLocation;
SafeAdd(lambda, lambda.Parameters, new ParameterDeclarationExpression(null, ident.Identifier));
lambda.Parameters[0].StartLocation = ident.StartLocation;
lambda.Parameters[0].EndLocation = ident.EndLocation;
-
- LambdaExpressionBody(lambda);
+
+ LambdaExpressionBody(
+#line 2104 "cs.ATG"
+lambda);
}
- void TypeArgumentList(out List types, bool canBeUnbound) {
+ void TypeArgumentList(
+#line 2345 "cs.ATG"
+out List types, bool canBeUnbound) {
+
+#line 2347 "cs.ATG"
types = new List();
TypeReference type = null;
-
+
Expect(23);
- if (canBeUnbound && (la.kind == Tokens.GreaterThan || la.kind == Tokens.Comma)) {
- types.Add(TypeReference.Null);
+ if (
+#line 2352 "cs.ATG"
+canBeUnbound && (la.kind == Tokens.GreaterThan || la.kind == Tokens.Comma)) {
+
+#line 2353 "cs.ATG"
+ types.Add(TypeReference.Null);
while (la.kind == 14) {
- Get();
- types.Add(TypeReference.Null);
+ lexer.NextToken();
+
+#line 2354 "cs.ATG"
+ types.Add(TypeReference.Null);
}
- } else if (StartOf(11)) {
- Type(out type);
- if (type != null) { types.Add(type); }
+ } else if (StartOf(10)) {
+ Type(
+#line 2355 "cs.ATG"
+out type);
+
+#line 2355 "cs.ATG"
+ if (type != null) { types.Add(type); }
while (la.kind == 14) {
- Get();
- Type(out type);
- if (type != null) { types.Add(type); }
+ lexer.NextToken();
+ Type(
+#line 2356 "cs.ATG"
+out type);
+
+#line 2356 "cs.ATG"
+ if (type != null) { types.Add(type); }
}
- } else SynErr(209);
+ } else SynErr(208);
Expect(22);
}
- void LambdaExpression(out Expression outExpr) {
+ void LambdaExpression(
+#line 2073 "cs.ATG"
+out Expression outExpr) {
+
+#line 2075 "cs.ATG"
LambdaExpression lambda = new LambdaExpression();
lambda.StartLocation = la.Location;
ParameterDeclarationExpression p;
outExpr = lambda;
-
+
Expect(20);
if (StartOf(36)) {
- LambdaExpressionParameter(out p);
- SafeAdd(lambda, lambda.Parameters, p);
+ LambdaExpressionParameter(
+#line 2083 "cs.ATG"
+out p);
+
+#line 2083 "cs.ATG"
+ SafeAdd(lambda, lambda.Parameters, p);
while (la.kind == 14) {
- Get();
- LambdaExpressionParameter(out p);
- SafeAdd(lambda, lambda.Parameters, p);
+ lexer.NextToken();
+ LambdaExpressionParameter(
+#line 2085 "cs.ATG"
+out p);
+
+#line 2085 "cs.ATG"
+ SafeAdd(lambda, lambda.Parameters, p);
}
}
Expect(21);
Expect(48);
- LambdaExpressionBody(lambda);
+ LambdaExpressionBody(
+#line 2090 "cs.ATG"
+lambda);
}
- void NewExpression(out Expression pexpr) {
+ void NewExpression(
+#line 2020 "cs.ATG"
+out Expression pexpr) {
+
+#line 2021 "cs.ATG"
pexpr = null;
List parameters = new List();
TypeReference type = null;
Expression expr;
-
+
Expect(89);
- if (StartOf(11)) {
- NonArrayType(out type);
+ if (StartOf(10)) {
+ NonArrayType(
+#line 2028 "cs.ATG"
+out type);
}
if (la.kind == 16 || la.kind == 20) {
if (la.kind == 20) {
- ObjectCreateExpression oce = new ObjectCreateExpression(type, parameters);
- Get();
- if (type == null) Error("Cannot use an anonymous type with arguments for the constructor");
+
+#line 2034 "cs.ATG"
+ ObjectCreateExpression oce = new ObjectCreateExpression(type, parameters);
+ lexer.NextToken();
+
+#line 2035 "cs.ATG"
+ if (type == null) Error("Cannot use an anonymous type with arguments for the constructor");
if (StartOf(25)) {
- Argument(out expr);
- SafeAdd(oce, parameters, expr);
+ Argument(
+#line 2036 "cs.ATG"
+out expr);
+
+#line 2036 "cs.ATG"
+ SafeAdd(oce, parameters, expr);
while (la.kind == 14) {
- Get();
- Argument(out expr);
- SafeAdd(oce, parameters, expr);
+ lexer.NextToken();
+ Argument(
+#line 2037 "cs.ATG"
+out expr);
+
+#line 2037 "cs.ATG"
+ SafeAdd(oce, parameters, expr);
}
}
Expect(21);
- pexpr = oce;
+
+#line 2039 "cs.ATG"
+ pexpr = oce;
if (la.kind == 16) {
- CollectionOrObjectInitializer(out expr);
- oce.ObjectInitializer = (CollectionInitializerExpression)expr;
+ CollectionOrObjectInitializer(
+#line 2040 "cs.ATG"
+out expr);
+
+#line 2040 "cs.ATG"
+ oce.ObjectInitializer = (CollectionInitializerExpression)expr;
}
} else {
- ObjectCreateExpression oce = new ObjectCreateExpression(type, parameters);
- CollectionOrObjectInitializer(out expr);
- oce.ObjectInitializer = (CollectionInitializerExpression)expr;
- pexpr = oce;
+
+#line 2041 "cs.ATG"
+ ObjectCreateExpression oce = new ObjectCreateExpression(type, parameters);
+ CollectionOrObjectInitializer(
+#line 2042 "cs.ATG"
+out expr);
+
+#line 2042 "cs.ATG"
+ oce.ObjectInitializer = (CollectionInitializerExpression)expr;
+
+#line 2043 "cs.ATG"
+ pexpr = oce;
}
} else if (la.kind == 18) {
- Get();
+ lexer.NextToken();
+
+#line 2048 "cs.ATG"
ArrayCreateExpression ace = new ArrayCreateExpression(type);
/* we must not change RankSpecifier on the null type reference*/
if (ace.CreateType.IsNull) { ace.CreateType = new TypeReference(""); }
pexpr = ace;
int dims = 0; List ranks = new List();
-
+
if (la.kind == 14 || la.kind == 19) {
while (la.kind == 14) {
- Get();
- dims += 1;
+ lexer.NextToken();
+
+#line 2055 "cs.ATG"
+ dims += 1;
}
Expect(19);
- ranks.Add(dims); dims = 0;
+
+#line 2056 "cs.ATG"
+ ranks.Add(dims); dims = 0;
while (la.kind == 18) {
- Get();
+ lexer.NextToken();
while (la.kind == 14) {
- Get();
- ++dims;
+ lexer.NextToken();
+
+#line 2057 "cs.ATG"
+ ++dims;
}
Expect(19);
- ranks.Add(dims); dims = 0;
+
+#line 2057 "cs.ATG"
+ ranks.Add(dims); dims = 0;
}
- ace.CreateType.RankSpecifier = ranks.ToArray();
- CollectionInitializer(out expr);
- ace.ArrayInitializer = (CollectionInitializerExpression)expr;
+
+#line 2058 "cs.ATG"
+ ace.CreateType.RankSpecifier = ranks.ToArray();
+ CollectionInitializer(
+#line 2059 "cs.ATG"
+out expr);
+
+#line 2059 "cs.ATG"
+ ace.ArrayInitializer = (CollectionInitializerExpression)expr;
} else if (StartOf(6)) {
- Expr(out expr);
- if (expr != null) parameters.Add(expr);
+ Expr(
+#line 2060 "cs.ATG"
+out expr);
+
+#line 2060 "cs.ATG"
+ if (expr != null) parameters.Add(expr);
while (la.kind == 14) {
- Get();
- dims += 1;
- Expr(out expr);
- if (expr != null) parameters.Add(expr);
+ lexer.NextToken();
+
+#line 2061 "cs.ATG"
+ dims += 1;
+ Expr(
+#line 2062 "cs.ATG"
+out expr);
+
+#line 2062 "cs.ATG"
+ if (expr != null) parameters.Add(expr);
}
Expect(19);
- ranks.Add(dims); ace.Arguments = parameters; dims = 0;
+
+#line 2064 "cs.ATG"
+ ranks.Add(dims); ace.Arguments = parameters; dims = 0;
while (la.kind == 18) {
- Get();
+ lexer.NextToken();
while (la.kind == 14) {
- Get();
- ++dims;
+ lexer.NextToken();
+
+#line 2065 "cs.ATG"
+ ++dims;
}
Expect(19);
- ranks.Add(dims); dims = 0;
+
+#line 2065 "cs.ATG"
+ ranks.Add(dims); dims = 0;
}
- ace.CreateType.RankSpecifier = ranks.ToArray();
+
+#line 2066 "cs.ATG"
+ ace.CreateType.RankSpecifier = ranks.ToArray();
if (la.kind == 16) {
- CollectionInitializer(out expr);
- ace.ArrayInitializer = (CollectionInitializerExpression)expr;
+ CollectionInitializer(
+#line 2067 "cs.ATG"
+out expr);
+
+#line 2067 "cs.ATG"
+ ace.ArrayInitializer = (CollectionInitializerExpression)expr;
}
- } else SynErr(210);
- } else SynErr(211);
+ } else SynErr(209);
+ } else SynErr(210);
}
- void AnonymousMethodExpr(out Expression outExpr) {
+ void AnonymousMethodExpr(
+#line 2140 "cs.ATG"
+out Expression outExpr) {
+
+#line 2142 "cs.ATG"
AnonymousMethodExpression expr = new AnonymousMethodExpression();
expr.StartLocation = t.Location;
BlockStatement stmt;
List p = new List();
outExpr = expr;
-
+
if (la.kind == 20) {
- Get();
- if (StartOf(12)) {
- FormalParameterList(p);
- expr.Parameters = p;
+ lexer.NextToken();
+ if (StartOf(11)) {
+ FormalParameterList(
+#line 2151 "cs.ATG"
+p);
+
+#line 2151 "cs.ATG"
+ expr.Parameters = p;
}
Expect(21);
- expr.HasParameterList = true;
+
+#line 2153 "cs.ATG"
+ expr.HasParameterList = true;
}
- BlockInsideExpression(out stmt);
- expr.Body = stmt;
- expr.EndLocation = t.Location;
+ BlockInsideExpression(
+#line 2155 "cs.ATG"
+out stmt);
+
+#line 2155 "cs.ATG"
+ expr.Body = stmt;
+
+#line 2156 "cs.ATG"
+ expr.EndLocation = t.Location;
}
- void PointerMemberAccess(out Expression expr, Expression target) {
- List typeList;
+ void PointerMemberAccess(
+#line 2008 "cs.ATG"
+out Expression expr, Expression target) {
+
+#line 2009 "cs.ATG"
+ List typeList;
Expect(47);
Identifier();
- expr = new PointerReferenceExpression(target, t.val); expr.StartLocation = t.Location; expr.EndLocation = t.EndLocation;
- if (IsGenericInSimpleNameOrMemberAccess()) {
- TypeArgumentList(out typeList, false);
- ((MemberReferenceExpression)expr).TypeArguments = typeList;
+
+#line 2013 "cs.ATG"
+ expr = new PointerReferenceExpression(target, t.val); expr.StartLocation = t.Location; expr.EndLocation = t.EndLocation;
+ if (
+#line 2014 "cs.ATG"
+IsGenericInSimpleNameOrMemberAccess()) {
+ TypeArgumentList(
+#line 2015 "cs.ATG"
+out typeList, false);
+
+#line 2016 "cs.ATG"
+ ((MemberReferenceExpression)expr).TypeArguments = typeList;
}
}
- void MemberAccess(out Expression expr, Expression target) {
- List typeList;
+ void MemberAccess(
+#line 1989 "cs.ATG"
+out Expression expr, Expression target) {
+
+#line 1990 "cs.ATG"
+ List typeList;
+
+#line 1992 "cs.ATG"
if (ShouldConvertTargetExpressionToTypeReference(target)) {
TypeReference type = GetTypeReferenceFromExpression(target);
if (type != null) {
target = new TypeReferenceExpression(type) { StartLocation = t.Location, EndLocation = t.EndLocation };
}
}
-
+
Expect(15);
- Location startLocation = t.Location;
+
+#line 1999 "cs.ATG"
+ Location startLocation = t.Location;
Identifier();
- expr = new MemberReferenceExpression(target, t.val); expr.StartLocation = startLocation; expr.EndLocation = t.EndLocation;
- if (IsGenericInSimpleNameOrMemberAccess()) {
- TypeArgumentList(out typeList, false);
- ((MemberReferenceExpression)expr).TypeArguments = typeList;
+
+#line 2001 "cs.ATG"
+ expr = new MemberReferenceExpression(target, t.val); expr.StartLocation = startLocation; expr.EndLocation = t.EndLocation;
+ if (
+#line 2002 "cs.ATG"
+IsGenericInSimpleNameOrMemberAccess()) {
+ TypeArgumentList(
+#line 2003 "cs.ATG"
+out typeList, false);
+
+#line 2004 "cs.ATG"
+ ((MemberReferenceExpression)expr).TypeArguments = typeList;
}
}
- void LambdaExpressionParameter(out ParameterDeclarationExpression p) {
+ void LambdaExpressionParameter(
+#line 2107 "cs.ATG"
+out ParameterDeclarationExpression p) {
+
+#line 2108 "cs.ATG"
Location start = la.Location; p = null;
TypeReference type;
ParameterModifiers mod = ParameterModifiers.In;
-
- if (Peek(1).kind == Tokens.Comma || Peek(1).kind == Tokens.CloseParenthesis) {
+
+ if (
+#line 2113 "cs.ATG"
+Peek(1).kind == Tokens.Comma || Peek(1).kind == Tokens.CloseParenthesis) {
Identifier();
+
+#line 2115 "cs.ATG"
p = new ParameterDeclarationExpression(null, t.val);
p.StartLocation = start; p.EndLocation = t.EndLocation;
-
+
} else if (StartOf(36)) {
if (la.kind == 93 || la.kind == 100) {
if (la.kind == 100) {
- Get();
- mod = ParameterModifiers.Ref;
+ lexer.NextToken();
+
+#line 2118 "cs.ATG"
+ mod = ParameterModifiers.Ref;
} else {
- Get();
- mod = ParameterModifiers.Out;
+ lexer.NextToken();
+
+#line 2119 "cs.ATG"
+ mod = ParameterModifiers.Out;
}
}
- Type(out type);
+ Type(
+#line 2121 "cs.ATG"
+out type);
Identifier();
+
+#line 2123 "cs.ATG"
p = new ParameterDeclarationExpression(type, t.val, mod);
p.StartLocation = start; p.EndLocation = t.EndLocation;
-
- } else SynErr(212);
+
+ } else SynErr(211);
}
- void LambdaExpressionBody(LambdaExpression lambda) {
- Expression expr; BlockStatement stmt;
+ void LambdaExpressionBody(
+#line 2129 "cs.ATG"
+LambdaExpression lambda) {
+
+#line 2130 "cs.ATG"
+ Expression expr; BlockStatement stmt;
if (la.kind == 16) {
- BlockInsideExpression(out stmt);
- lambda.StatementBody = stmt;
+ BlockInsideExpression(
+#line 2133 "cs.ATG"
+out stmt);
+
+#line 2133 "cs.ATG"
+ lambda.StatementBody = stmt;
} else if (StartOf(6)) {
- Expr(out expr);
- lambda.ExpressionBody = expr;
- } else SynErr(213);
- lambda.EndLocation = t.EndLocation;
- lambda.ExtendedEndLocation = la.Location;
- }
-
- void BlockInsideExpression(out BlockStatement outStmt) {
- Statement stmt = null; outStmt = null;
- if (compilationUnit != null) {
- Block(out stmt);
- outStmt = (BlockStatement)stmt;
- } else {
+ Expr(
+#line 2134 "cs.ATG"
+out expr);
+
+#line 2134 "cs.ATG"
+ lambda.ExpressionBody = expr;
+ } else SynErr(212);
+
+#line 2136 "cs.ATG"
+ lambda.EndLocation = t.EndLocation;
+
+#line 2137 "cs.ATG"
+ lambda.ExtendedEndLocation = la.Location;
+ }
+
+ void BlockInsideExpression(
+#line 2159 "cs.ATG"
+out BlockStatement outStmt) {
+
+#line 2160 "cs.ATG"
+ Statement stmt = null; outStmt = null;
+
+#line 2164 "cs.ATG"
+ if (compilationUnit != null) {
+ Block(
+#line 2165 "cs.ATG"
+out stmt);
+
+#line 2165 "cs.ATG"
+ outStmt = (BlockStatement)stmt;
+
+#line 2166 "cs.ATG"
+ } else {
Expect(16);
- lexer.SkipCurrentBlock(0);
+
+#line 2168 "cs.ATG"
+ lexer.SkipCurrentBlock(0);
Expect(17);
- }
+
+#line 2170 "cs.ATG"
+ }
}
- void ConditionalAndExpr(ref Expression outExpr) {
- Expression expr;
- InclusiveOrExpr(ref outExpr);
+ void ConditionalAndExpr(
+#line 2179 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2180 "cs.ATG"
+ Expression expr;
+ InclusiveOrExpr(
+#line 2182 "cs.ATG"
+ref outExpr);
while (la.kind == 25) {
- Get();
- UnaryExpr(out expr);
- InclusiveOrExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.LogicalAnd, expr);
+ lexer.NextToken();
+ UnaryExpr(
+#line 2182 "cs.ATG"
+out expr);
+ InclusiveOrExpr(
+#line 2182 "cs.ATG"
+ref expr);
+
+#line 2182 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.LogicalAnd, expr);
}
}
- void InclusiveOrExpr(ref Expression outExpr) {
- Expression expr;
- ExclusiveOrExpr(ref outExpr);
+ void InclusiveOrExpr(
+#line 2185 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2186 "cs.ATG"
+ Expression expr;
+ ExclusiveOrExpr(
+#line 2188 "cs.ATG"
+ref outExpr);
while (la.kind == 29) {
- Get();
- UnaryExpr(out expr);
- ExclusiveOrExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.BitwiseOr, expr);
+ lexer.NextToken();
+ UnaryExpr(
+#line 2188 "cs.ATG"
+out expr);
+ ExclusiveOrExpr(
+#line 2188 "cs.ATG"
+ref expr);
+
+#line 2188 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.BitwiseOr, expr);
}
}
- void ExclusiveOrExpr(ref Expression outExpr) {
- Expression expr;
- AndExpr(ref outExpr);
+ void ExclusiveOrExpr(
+#line 2191 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2192 "cs.ATG"
+ Expression expr;
+ AndExpr(
+#line 2194 "cs.ATG"
+ref outExpr);
while (la.kind == 30) {
- Get();
- UnaryExpr(out expr);
- AndExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.ExclusiveOr, expr);
+ lexer.NextToken();
+ UnaryExpr(
+#line 2194 "cs.ATG"
+out expr);
+ AndExpr(
+#line 2194 "cs.ATG"
+ref expr);
+
+#line 2194 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.ExclusiveOr, expr);
}
}
- void AndExpr(ref Expression outExpr) {
- Expression expr;
- EqualityExpr(ref outExpr);
+ void AndExpr(
+#line 2197 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2198 "cs.ATG"
+ Expression expr;
+ EqualityExpr(
+#line 2200 "cs.ATG"
+ref outExpr);
while (la.kind == 28) {
- Get();
- UnaryExpr(out expr);
- EqualityExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.BitwiseAnd, expr);
+ lexer.NextToken();
+ UnaryExpr(
+#line 2200 "cs.ATG"
+out expr);
+ EqualityExpr(
+#line 2200 "cs.ATG"
+ref expr);
+
+#line 2200 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.BitwiseAnd, expr);
}
}
- void EqualityExpr(ref Expression outExpr) {
+ void EqualityExpr(
+#line 2203 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2205 "cs.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- RelationalExpr(ref outExpr);
+
+ RelationalExpr(
+#line 2209 "cs.ATG"
+ref outExpr);
while (la.kind == 33 || la.kind == 34) {
if (la.kind == 34) {
- Get();
- op = BinaryOperatorType.InEquality;
+ lexer.NextToken();
+
+#line 2212 "cs.ATG"
+ op = BinaryOperatorType.InEquality;
} else {
- Get();
- op = BinaryOperatorType.Equality;
+ lexer.NextToken();
+
+#line 2213 "cs.ATG"
+ op = BinaryOperatorType.Equality;
}
- UnaryExpr(out expr);
- RelationalExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ UnaryExpr(
+#line 2215 "cs.ATG"
+out expr);
+ RelationalExpr(
+#line 2215 "cs.ATG"
+ref expr);
+
+#line 2215 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void RelationalExpr(ref Expression outExpr) {
+ void RelationalExpr(
+#line 2219 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2221 "cs.ATG"
TypeReference type;
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- ShiftExpr(ref outExpr);
+
+ ShiftExpr(
+#line 2226 "cs.ATG"
+ref outExpr);
while (StartOf(37)) {
if (StartOf(38)) {
if (la.kind == 23) {
- Get();
- op = BinaryOperatorType.LessThan;
+ lexer.NextToken();
+
+#line 2228 "cs.ATG"
+ op = BinaryOperatorType.LessThan;
} else if (la.kind == 22) {
- Get();
- op = BinaryOperatorType.GreaterThan;
+ lexer.NextToken();
+
+#line 2229 "cs.ATG"
+ op = BinaryOperatorType.GreaterThan;
} else if (la.kind == 36) {
- Get();
- op = BinaryOperatorType.LessThanOrEqual;
- } else {
- Get();
- op = BinaryOperatorType.GreaterThanOrEqual;
- }
- UnaryExpr(out expr);
- ShiftExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ lexer.NextToken();
+
+#line 2230 "cs.ATG"
+ op = BinaryOperatorType.LessThanOrEqual;
+ } else if (la.kind == 35) {
+ lexer.NextToken();
+
+#line 2231 "cs.ATG"
+ op = BinaryOperatorType.GreaterThanOrEqual;
+ } else SynErr(213);
+ UnaryExpr(
+#line 2233 "cs.ATG"
+out expr);
+ ShiftExpr(
+#line 2234 "cs.ATG"
+ref expr);
+
+#line 2235 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
} else {
if (la.kind == 85) {
- Get();
- TypeWithRestriction(out type, false, false);
- if (la.kind == Tokens.Question && !IsPossibleExpressionStart(Peek(1).kind)) {
- NullableQuestionMark(ref type);
+ lexer.NextToken();
+ TypeWithRestriction(
+#line 2238 "cs.ATG"
+out type, false, false);
+ if (
+#line 2239 "cs.ATG"
+la.kind == Tokens.Question && !IsPossibleExpressionStart(Peek(1).kind)) {
+ NullableQuestionMark(
+#line 2240 "cs.ATG"
+ref type);
}
- outExpr = new TypeOfIsExpression(outExpr, type);
- } else {
- Get();
- TypeWithRestriction(out type, false, false);
- if (la.kind == Tokens.Question && !IsPossibleExpressionStart(Peek(1).kind)) {
- NullableQuestionMark(ref type);
+
+#line 2241 "cs.ATG"
+ outExpr = new TypeOfIsExpression(outExpr, type);
+ } else if (la.kind == 50) {
+ lexer.NextToken();
+ TypeWithRestriction(
+#line 2243 "cs.ATG"
+out type, false, false);
+ if (
+#line 2244 "cs.ATG"
+la.kind == Tokens.Question && !IsPossibleExpressionStart(Peek(1).kind)) {
+ NullableQuestionMark(
+#line 2245 "cs.ATG"
+ref type);
}
- outExpr = new CastExpression(type, outExpr, CastType.TryCast);
- }
+
+#line 2246 "cs.ATG"
+ outExpr = new CastExpression(type, outExpr, CastType.TryCast);
+ } else SynErr(214);
}
}
}
- void ShiftExpr(ref Expression outExpr) {
+ void ShiftExpr(
+#line 2251 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2253 "cs.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- AdditiveExpr(ref outExpr);
- while (la.kind == 22 || la.kind == 37) {
+
+ AdditiveExpr(
+#line 2257 "cs.ATG"
+ref outExpr);
+ while (la.kind == 37 ||
+#line 2260 "cs.ATG"
+IsShiftRight()) {
if (la.kind == 37) {
- Get();
- op = BinaryOperatorType.ShiftLeft;
+ lexer.NextToken();
+
+#line 2259 "cs.ATG"
+ op = BinaryOperatorType.ShiftLeft;
} else {
Expect(22);
Expect(22);
- op = BinaryOperatorType.ShiftRight;
+
+#line 2261 "cs.ATG"
+ op = BinaryOperatorType.ShiftRight;
}
- UnaryExpr(out expr);
- AdditiveExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ UnaryExpr(
+#line 2264 "cs.ATG"
+out expr);
+ AdditiveExpr(
+#line 2264 "cs.ATG"
+ref expr);
+
+#line 2264 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void AdditiveExpr(ref Expression outExpr) {
+ void AdditiveExpr(
+#line 2268 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2270 "cs.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- MultiplicativeExpr(ref outExpr);
+
+ MultiplicativeExpr(
+#line 2274 "cs.ATG"
+ref outExpr);
while (la.kind == 4 || la.kind == 5) {
if (la.kind == 4) {
- Get();
- op = BinaryOperatorType.Add;
+ lexer.NextToken();
+
+#line 2277 "cs.ATG"
+ op = BinaryOperatorType.Add;
} else {
- Get();
- op = BinaryOperatorType.Subtract;
+ lexer.NextToken();
+
+#line 2278 "cs.ATG"
+ op = BinaryOperatorType.Subtract;
}
- UnaryExpr(out expr);
- MultiplicativeExpr(ref expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ UnaryExpr(
+#line 2280 "cs.ATG"
+out expr);
+ MultiplicativeExpr(
+#line 2280 "cs.ATG"
+ref expr);
+
+#line 2280 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void MultiplicativeExpr(ref Expression outExpr) {
+ void MultiplicativeExpr(
+#line 2284 "cs.ATG"
+ref Expression outExpr) {
+
+#line 2286 "cs.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
+
while (la.kind == 6 || la.kind == 7 || la.kind == 8) {
if (la.kind == 6) {
- Get();
- op = BinaryOperatorType.Multiply;
+ lexer.NextToken();
+
+#line 2292 "cs.ATG"
+ op = BinaryOperatorType.Multiply;
} else if (la.kind == 7) {
- Get();
- op = BinaryOperatorType.Divide;
+ lexer.NextToken();
+
+#line 2293 "cs.ATG"
+ op = BinaryOperatorType.Divide;
} else {
- Get();
- op = BinaryOperatorType.Modulus;
+ lexer.NextToken();
+
+#line 2294 "cs.ATG"
+ op = BinaryOperatorType.Modulus;
}
- UnaryExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ UnaryExpr(
+#line 2296 "cs.ATG"
+out expr);
+
+#line 2296 "cs.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void VariantTypeParameter(out TemplateDefinition typeParameter) {
+ void VariantTypeParameter(
+#line 2374 "cs.ATG"
+out TemplateDefinition typeParameter) {
+
+#line 2376 "cs.ATG"
typeParameter = new TemplateDefinition();
AttributeSection section;
-
+
while (la.kind == 18) {
- AttributeSection(out section);
- typeParameter.Attributes.Add(section);
+ AttributeSection(
+#line 2380 "cs.ATG"
+out section);
+
+#line 2380 "cs.ATG"
+ typeParameter.Attributes.Add(section);
}
if (la.kind == 81 || la.kind == 93) {
if (la.kind == 81) {
- Get();
- typeParameter.VarianceModifier = VarianceModifier.Contravariant;
+ lexer.NextToken();
+
+#line 2382 "cs.ATG"
+ typeParameter.VarianceModifier = VarianceModifier.Contravariant;
} else {
- Get();
- typeParameter.VarianceModifier = VarianceModifier.Covariant;
+ lexer.NextToken();
+
+#line 2383 "cs.ATG"
+ typeParameter.VarianceModifier = VarianceModifier.Covariant;
}
}
Identifier();
- typeParameter.Name = t.val; typeParameter.StartLocation = t.Location;
- typeParameter.EndLocation = t.EndLocation;
+
+#line 2385 "cs.ATG"
+ typeParameter.Name = t.val; typeParameter.StartLocation = t.Location;
+
+#line 2386 "cs.ATG"
+ typeParameter.EndLocation = t.EndLocation;
}
- void TypeParameterConstraintsClauseBase(out TypeReference type) {
- TypeReference t; type = null;
+ void TypeParameterConstraintsClauseBase(
+#line 2417 "cs.ATG"
+out TypeReference type) {
+
+#line 2418 "cs.ATG"
+ TypeReference t; type = null;
if (la.kind == 109) {
- Get();
- type = TypeReference.StructConstraint;
+ lexer.NextToken();
+
+#line 2420 "cs.ATG"
+ type = TypeReference.StructConstraint;
} else if (la.kind == 59) {
- Get();
- type = TypeReference.ClassConstraint;
+ lexer.NextToken();
+
+#line 2421 "cs.ATG"
+ type = TypeReference.ClassConstraint;
} else if (la.kind == 89) {
- Get();
+ lexer.NextToken();
Expect(20);
Expect(21);
- type = TypeReference.NewConstraint;
- } else if (StartOf(11)) {
- Type(out t);
- type = t;
- } else SynErr(214);
+
+#line 2422 "cs.ATG"
+ type = TypeReference.NewConstraint;
+ } else if (StartOf(10)) {
+ Type(
+#line 2423 "cs.ATG"
+out t);
+
+#line 2423 "cs.ATG"
+ type = t;
+ } else SynErr(215);
}
- void QueryExpressionFromClause(out QueryExpressionFromClause fc) {
+ void QueryExpressionFromClause(
+#line 2438 "cs.ATG"
+out QueryExpressionFromClause fc) {
+
+#line 2439 "cs.ATG"
fc = new QueryExpressionFromClause();
fc.StartLocation = la.Location;
CollectionRangeVariable variable;
-
+
Expect(137);
- QueryExpressionFromOrJoinClause(out variable);
+ QueryExpressionFromOrJoinClause(
+#line 2445 "cs.ATG"
+out variable);
+
+#line 2446 "cs.ATG"
fc.EndLocation = t.EndLocation;
fc.Sources.Add(variable);
-
+
}
- void QueryExpressionBody(ref QueryExpression q) {
+ void QueryExpressionBody(
+#line 2482 "cs.ATG"
+ref QueryExpression q) {
+
+#line 2483 "cs.ATG"
QueryExpressionFromClause fromClause; QueryExpressionWhereClause whereClause;
QueryExpressionLetClause letClause; QueryExpressionJoinClause joinClause;
QueryExpressionOrderClause orderClause;
QueryExpressionSelectClause selectClause; QueryExpressionGroupClause groupClause;
-
+
while (StartOf(39)) {
if (la.kind == 137) {
- QueryExpressionFromClause(out fromClause);
- SafeAdd(q, q.MiddleClauses, fromClause);
+ QueryExpressionFromClause(
+#line 2489 "cs.ATG"
+out fromClause);
+
+#line 2489 "cs.ATG"
+ SafeAdd(q, q.MiddleClauses, fromClause);
} else if (la.kind == 127) {
- QueryExpressionWhereClause(out whereClause);
- SafeAdd(q, q.MiddleClauses, whereClause);
+ QueryExpressionWhereClause(
+#line 2490 "cs.ATG"
+out whereClause);
+
+#line 2490 "cs.ATG"
+ SafeAdd(q, q.MiddleClauses, whereClause);
} else if (la.kind == 141) {
- QueryExpressionLetClause(out letClause);
- SafeAdd(q, q.MiddleClauses, letClause);
+ QueryExpressionLetClause(
+#line 2491 "cs.ATG"
+out letClause);
+
+#line 2491 "cs.ATG"
+ SafeAdd(q, q.MiddleClauses, letClause);
} else if (la.kind == 142) {
- QueryExpressionJoinClause(out joinClause);
- SafeAdd(q, q.MiddleClauses, joinClause);
+ QueryExpressionJoinClause(
+#line 2492 "cs.ATG"
+out joinClause);
+
+#line 2492 "cs.ATG"
+ SafeAdd(q, q.MiddleClauses, joinClause);
} else {
- QueryExpressionOrderByClause(out orderClause);
- SafeAdd(q, q.MiddleClauses, orderClause);
+ QueryExpressionOrderByClause(
+#line 2493 "cs.ATG"
+out orderClause);
+
+#line 2493 "cs.ATG"
+ SafeAdd(q, q.MiddleClauses, orderClause);
}
}
if (la.kind == 133) {
- QueryExpressionSelectClause(out selectClause);
- q.SelectOrGroupClause = selectClause;
+ QueryExpressionSelectClause(
+#line 2495 "cs.ATG"
+out selectClause);
+
+#line 2495 "cs.ATG"
+ q.SelectOrGroupClause = selectClause;
} else if (la.kind == 134) {
- QueryExpressionGroupClause(out groupClause);
- q.SelectOrGroupClause = groupClause;
- } else SynErr(215);
+ QueryExpressionGroupClause(
+#line 2496 "cs.ATG"
+out groupClause);
+
+#line 2496 "cs.ATG"
+ q.SelectOrGroupClause = groupClause;
+ } else SynErr(216);
if (la.kind == 136) {
- QueryExpressionIntoClause(ref q);
+ QueryExpressionIntoClause(
+#line 2498 "cs.ATG"
+ref q);
}
}
- void QueryExpressionFromOrJoinClause(out CollectionRangeVariable variable) {
- TypeReference type; Expression expr; variable = new CollectionRangeVariable();
- variable.Type = null;
- if (IsLocalVarDecl()) {
- Type(out type);
- variable.Type = type;
+ void QueryExpressionFromOrJoinClause(
+#line 2472 "cs.ATG"
+out CollectionRangeVariable variable) {
+
+#line 2473 "cs.ATG"
+ TypeReference type; Expression expr; variable = new CollectionRangeVariable();
+
+#line 2475 "cs.ATG"
+ variable.Type = null;
+ if (
+#line 2476 "cs.ATG"
+IsLocalVarDecl()) {
+ Type(
+#line 2476 "cs.ATG"
+out type);
+
+#line 2476 "cs.ATG"
+ variable.Type = type;
}
Identifier();
- variable.Identifier = t.val;
+
+#line 2477 "cs.ATG"
+ variable.Identifier = t.val;
Expect(81);
- Expr(out expr);
- variable.Expression = expr;
+ Expr(
+#line 2479 "cs.ATG"
+out expr);
+
+#line 2479 "cs.ATG"
+ variable.Expression = expr;
}
- void QueryExpressionJoinClause(out QueryExpressionJoinClause jc) {
+ void QueryExpressionJoinClause(
+#line 2451 "cs.ATG"
+out QueryExpressionJoinClause jc) {
+
+#line 2452 "cs.ATG"
jc = new QueryExpressionJoinClause(); jc.StartLocation = la.Location;
Expression expr;
CollectionRangeVariable variable;
-
+
Expect(142);
- QueryExpressionFromOrJoinClause(out variable);
+ QueryExpressionFromOrJoinClause(
+#line 2458 "cs.ATG"
+out variable);
Expect(143);
- Expr(out expr);
- jc.OnExpression = expr;
+ Expr(
+#line 2460 "cs.ATG"
+out expr);
+
+#line 2460 "cs.ATG"
+ jc.OnExpression = expr;
Expect(144);
- Expr(out expr);
- jc.EqualsExpression = expr;
+ Expr(
+#line 2462 "cs.ATG"
+out expr);
+
+#line 2462 "cs.ATG"
+ jc.EqualsExpression = expr;
if (la.kind == 136) {
- Get();
+ lexer.NextToken();
Identifier();
- jc.IntoIdentifier = t.val;
+
+#line 2464 "cs.ATG"
+ jc.IntoIdentifier = t.val;
}
+
+#line 2467 "cs.ATG"
jc.EndLocation = t.EndLocation;
jc.Source = variable;
-
+
}
- void QueryExpressionWhereClause(out QueryExpressionWhereClause wc) {
- Expression expr; wc = new QueryExpressionWhereClause(); wc.StartLocation = la.Location;
+ void QueryExpressionWhereClause(
+#line 2501 "cs.ATG"
+out QueryExpressionWhereClause wc) {
+
+#line 2502 "cs.ATG"
+ Expression expr; wc = new QueryExpressionWhereClause(); wc.StartLocation = la.Location;
Expect(127);
- Expr(out expr);
- wc.Condition = expr;
- wc.EndLocation = t.EndLocation;
+ Expr(
+#line 2505 "cs.ATG"
+out expr);
+
+#line 2505 "cs.ATG"
+ wc.Condition = expr;
+
+#line 2506 "cs.ATG"
+ wc.EndLocation = t.EndLocation;
}
- void QueryExpressionLetClause(out QueryExpressionLetClause wc) {
- Expression expr; wc = new QueryExpressionLetClause(); wc.StartLocation = la.Location;
+ void QueryExpressionLetClause(
+#line 2509 "cs.ATG"
+out QueryExpressionLetClause wc) {
+
+#line 2510 "cs.ATG"
+ Expression expr; wc = new QueryExpressionLetClause(); wc.StartLocation = la.Location;
Expect(141);
Identifier();
- wc.Identifier = t.val;
+
+#line 2513 "cs.ATG"
+ wc.Identifier = t.val;
Expect(3);
- Expr(out expr);
- wc.Expression = expr;
- wc.EndLocation = t.EndLocation;
+ Expr(
+#line 2515 "cs.ATG"
+out expr);
+
+#line 2515 "cs.ATG"
+ wc.Expression = expr;
+
+#line 2516 "cs.ATG"
+ wc.EndLocation = t.EndLocation;
}
- void QueryExpressionOrderByClause(out QueryExpressionOrderClause oc) {
- QueryExpressionOrdering ordering; oc = new QueryExpressionOrderClause(); oc.StartLocation = la.Location;
+ void QueryExpressionOrderByClause(
+#line 2519 "cs.ATG"
+out QueryExpressionOrderClause oc) {
+
+#line 2520 "cs.ATG"
+ QueryExpressionOrdering ordering; oc = new QueryExpressionOrderClause(); oc.StartLocation = la.Location;
Expect(140);
- QueryExpressionOrdering(out ordering);
- SafeAdd(oc, oc.Orderings, ordering);
+ QueryExpressionOrdering(
+#line 2523 "cs.ATG"
+out ordering);
+
+#line 2523 "cs.ATG"
+ SafeAdd(oc, oc.Orderings, ordering);
while (la.kind == 14) {
- Get();
- QueryExpressionOrdering(out ordering);
- SafeAdd(oc, oc.Orderings, ordering);
+ lexer.NextToken();
+ QueryExpressionOrdering(
+#line 2525 "cs.ATG"
+out ordering);
+
+#line 2525 "cs.ATG"
+ SafeAdd(oc, oc.Orderings, ordering);
}
- oc.EndLocation = t.EndLocation;
+
+#line 2527 "cs.ATG"
+ oc.EndLocation = t.EndLocation;
}
- void QueryExpressionSelectClause(out QueryExpressionSelectClause sc) {
- Expression expr; sc = new QueryExpressionSelectClause(); sc.StartLocation = la.Location;
+ void QueryExpressionSelectClause(
+#line 2540 "cs.ATG"
+out QueryExpressionSelectClause sc) {
+
+#line 2541 "cs.ATG"
+ Expression expr; sc = new QueryExpressionSelectClause(); sc.StartLocation = la.Location;
Expect(133);
- Expr(out expr);
- sc.Projection = expr;
- sc.EndLocation = t.EndLocation;
+ Expr(
+#line 2544 "cs.ATG"
+out expr);
+
+#line 2544 "cs.ATG"
+ sc.Projection = expr;
+
+#line 2545 "cs.ATG"
+ sc.EndLocation = t.EndLocation;
}
- void QueryExpressionGroupClause(out QueryExpressionGroupClause gc) {
- Expression expr; gc = new QueryExpressionGroupClause(); gc.StartLocation = la.Location;
+ void QueryExpressionGroupClause(
+#line 2548 "cs.ATG"
+out QueryExpressionGroupClause gc) {
+
+#line 2549 "cs.ATG"
+ Expression expr; gc = new QueryExpressionGroupClause(); gc.StartLocation = la.Location;
Expect(134);
- Expr(out expr);
- gc.Projection = expr;
+ Expr(
+#line 2552 "cs.ATG"
+out expr);
+
+#line 2552 "cs.ATG"
+ gc.Projection = expr;
Expect(135);
- Expr(out expr);
- gc.GroupBy = expr;
- gc.EndLocation = t.EndLocation;
+ Expr(
+#line 2554 "cs.ATG"
+out expr);
+
+#line 2554 "cs.ATG"
+ gc.GroupBy = expr;
+
+#line 2555 "cs.ATG"
+ gc.EndLocation = t.EndLocation;
}
- void QueryExpressionIntoClause(ref QueryExpression q) {
+ void QueryExpressionIntoClause(
+#line 2558 "cs.ATG"
+ref QueryExpression q) {
+
+#line 2559 "cs.ATG"
QueryExpression firstQuery = q;
QueryExpression continuedQuery = new QueryExpression();
continuedQuery.StartLocation = q.StartLocation;
@@ -3536,28 +5862,48 @@ partial class Parser : AbstractParser
fromVariable.Expression = firstQuery;
continuedQuery.IsQueryContinuation = true;
q = continuedQuery;
-
+
Expect(136);
Identifier();
- fromVariable.Identifier = t.val;
- continuedQuery.FromClause.EndLocation = t.EndLocation;
- QueryExpressionBody(ref q);
+
+#line 2574 "cs.ATG"
+ fromVariable.Identifier = t.val;
+
+#line 2575 "cs.ATG"
+ continuedQuery.FromClause.EndLocation = t.EndLocation;
+ QueryExpressionBody(
+#line 2576 "cs.ATG"
+ref q);
}
- void QueryExpressionOrdering(out QueryExpressionOrdering ordering) {
- Expression expr; ordering = new QueryExpressionOrdering(); ordering.StartLocation = la.Location;
- Expr(out expr);
- ordering.Criteria = expr;
+ void QueryExpressionOrdering(
+#line 2530 "cs.ATG"
+out QueryExpressionOrdering ordering) {
+
+#line 2531 "cs.ATG"
+ Expression expr; ordering = new QueryExpressionOrdering(); ordering.StartLocation = la.Location;
+ Expr(
+#line 2533 "cs.ATG"
+out expr);
+
+#line 2533 "cs.ATG"
+ ordering.Criteria = expr;
if (la.kind == 138 || la.kind == 139) {
if (la.kind == 138) {
- Get();
- ordering.Direction = QueryExpressionOrderingDirection.Ascending;
+ lexer.NextToken();
+
+#line 2534 "cs.ATG"
+ ordering.Direction = QueryExpressionOrderingDirection.Ascending;
} else {
- Get();
- ordering.Direction = QueryExpressionOrderingDirection.Descending;
+ lexer.NextToken();
+
+#line 2535 "cs.ATG"
+ ordering.Direction = QueryExpressionOrderingDirection.Descending;
}
}
- ordering.EndLocation = t.EndLocation;
+
+#line 2537 "cs.ATG"
+ ordering.EndLocation = t.EndLocation;
}
@@ -3565,288 +5911,284 @@ partial class Parser : AbstractParser
void ParseRoot()
{
CS();
- Expect(0); // expect end-of-file automatically added
}
- private bool StartOf(int s)
- {
- return set[s, lexer.LookAhead.kind];
- }
-
protected override void SynErr(int line, int col, int errorNumber)
{
- this.Errors.Error(line, col, ErrorDesc(errorNumber));
+ string s;
+ switch (errorNumber) {
+ case 0: s = "EOF expected"; break;
+ case 1: s = "ident expected"; break;
+ case 2: s = "Literal expected"; break;
+ case 3: s = "\"=\" expected"; break;
+ case 4: s = "\"+\" expected"; break;
+ case 5: s = "\"-\" expected"; break;
+ case 6: s = "\"*\" expected"; break;
+ case 7: s = "\"/\" expected"; break;
+ case 8: s = "\"%\" expected"; break;
+ case 9: s = "\":\" expected"; break;
+ case 10: s = "\"::\" expected"; break;
+ case 11: s = "\";\" expected"; break;
+ case 12: s = "\"?\" expected"; break;
+ case 13: s = "\"??\" expected"; break;
+ case 14: s = "\",\" expected"; break;
+ case 15: s = "\".\" expected"; break;
+ case 16: s = "\"{\" expected"; break;
+ case 17: s = "\"}\" expected"; break;
+ case 18: s = "\"[\" expected"; break;
+ case 19: s = "\"]\" expected"; break;
+ case 20: s = "\"(\" expected"; break;
+ case 21: s = "\")\" expected"; break;
+ case 22: s = "\">\" expected"; break;
+ case 23: s = "\"<\" expected"; break;
+ case 24: s = "\"!\" expected"; break;
+ case 25: s = "\"&&\" expected"; break;
+ case 26: s = "\"||\" expected"; break;
+ case 27: s = "\"~\" expected"; break;
+ case 28: s = "\"&\" expected"; break;
+ case 29: s = "\"|\" expected"; break;
+ case 30: s = "\"^\" expected"; break;
+ case 31: s = "\"++\" expected"; break;
+ case 32: s = "\"--\" expected"; break;
+ case 33: s = "\"==\" expected"; break;
+ case 34: s = "\"!=\" expected"; break;
+ case 35: s = "\">=\" expected"; break;
+ case 36: s = "\"<=\" expected"; break;
+ case 37: s = "\"<<\" expected"; break;
+ case 38: s = "\"+=\" expected"; break;
+ case 39: s = "\"-=\" expected"; break;
+ case 40: s = "\"*=\" expected"; break;
+ case 41: s = "\"/=\" expected"; break;
+ case 42: s = "\"%=\" expected"; break;
+ case 43: s = "\"&=\" expected"; break;
+ case 44: s = "\"|=\" expected"; break;
+ case 45: s = "\"^=\" expected"; break;
+ case 46: s = "\"<<=\" expected"; break;
+ case 47: s = "\"->\" expected"; break;
+ case 48: s = "\"=>\" expected"; break;
+ case 49: s = "\"abstract\" expected"; break;
+ case 50: s = "\"as\" expected"; break;
+ case 51: s = "\"base\" expected"; break;
+ case 52: s = "\"bool\" expected"; break;
+ case 53: s = "\"break\" expected"; break;
+ case 54: s = "\"byte\" expected"; break;
+ case 55: s = "\"case\" expected"; break;
+ case 56: s = "\"catch\" expected"; break;
+ case 57: s = "\"char\" expected"; break;
+ case 58: s = "\"checked\" expected"; break;
+ case 59: s = "\"class\" expected"; break;
+ case 60: s = "\"const\" expected"; break;
+ case 61: s = "\"continue\" expected"; break;
+ case 62: s = "\"decimal\" expected"; break;
+ case 63: s = "\"default\" expected"; break;
+ case 64: s = "\"delegate\" expected"; break;
+ case 65: s = "\"do\" expected"; break;
+ case 66: s = "\"double\" expected"; break;
+ case 67: s = "\"else\" expected"; break;
+ case 68: s = "\"enum\" expected"; break;
+ case 69: s = "\"event\" expected"; break;
+ case 70: s = "\"explicit\" expected"; break;
+ case 71: s = "\"extern\" expected"; break;
+ case 72: s = "\"false\" expected"; break;
+ case 73: s = "\"finally\" expected"; break;
+ case 74: s = "\"fixed\" expected"; break;
+ case 75: s = "\"float\" expected"; break;
+ case 76: s = "\"for\" expected"; break;
+ case 77: s = "\"foreach\" expected"; break;
+ case 78: s = "\"goto\" expected"; break;
+ case 79: s = "\"if\" expected"; break;
+ case 80: s = "\"implicit\" expected"; break;
+ case 81: s = "\"in\" expected"; break;
+ case 82: s = "\"int\" expected"; break;
+ case 83: s = "\"interface\" expected"; break;
+ case 84: s = "\"internal\" expected"; break;
+ case 85: s = "\"is\" expected"; break;
+ case 86: s = "\"lock\" expected"; break;
+ case 87: s = "\"long\" expected"; break;
+ case 88: s = "\"namespace\" expected"; break;
+ case 89: s = "\"new\" expected"; break;
+ case 90: s = "\"null\" expected"; break;
+ case 91: s = "\"object\" expected"; break;
+ case 92: s = "\"operator\" expected"; break;
+ case 93: s = "\"out\" expected"; break;
+ case 94: s = "\"override\" expected"; break;
+ case 95: s = "\"params\" expected"; break;
+ case 96: s = "\"private\" expected"; break;
+ case 97: s = "\"protected\" expected"; break;
+ case 98: s = "\"public\" expected"; break;
+ case 99: s = "\"readonly\" expected"; break;
+ case 100: s = "\"ref\" expected"; break;
+ case 101: s = "\"return\" expected"; break;
+ case 102: s = "\"sbyte\" expected"; break;
+ case 103: s = "\"sealed\" expected"; break;
+ case 104: s = "\"short\" expected"; break;
+ case 105: s = "\"sizeof\" expected"; break;
+ case 106: s = "\"stackalloc\" expected"; break;
+ case 107: s = "\"static\" expected"; break;
+ case 108: s = "\"string\" expected"; break;
+ case 109: s = "\"struct\" expected"; break;
+ case 110: s = "\"switch\" expected"; break;
+ case 111: s = "\"this\" expected"; break;
+ case 112: s = "\"throw\" expected"; break;
+ case 113: s = "\"true\" expected"; break;
+ case 114: s = "\"try\" expected"; break;
+ case 115: s = "\"typeof\" expected"; break;
+ case 116: s = "\"uint\" expected"; break;
+ case 117: s = "\"ulong\" expected"; break;
+ case 118: s = "\"unchecked\" expected"; break;
+ case 119: s = "\"unsafe\" expected"; break;
+ case 120: s = "\"ushort\" expected"; break;
+ case 121: s = "\"using\" expected"; break;
+ case 122: s = "\"virtual\" expected"; break;
+ case 123: s = "\"void\" expected"; break;
+ case 124: s = "\"volatile\" expected"; break;
+ case 125: s = "\"while\" expected"; break;
+ case 126: s = "\"partial\" expected"; break;
+ case 127: s = "\"where\" expected"; break;
+ case 128: s = "\"get\" expected"; break;
+ case 129: s = "\"set\" expected"; break;
+ case 130: s = "\"add\" expected"; break;
+ case 131: s = "\"remove\" expected"; break;
+ case 132: s = "\"yield\" expected"; break;
+ case 133: s = "\"select\" expected"; break;
+ case 134: s = "\"group\" expected"; break;
+ case 135: s = "\"by\" expected"; break;
+ case 136: s = "\"into\" expected"; break;
+ case 137: s = "\"from\" expected"; break;
+ case 138: s = "\"ascending\" expected"; break;
+ case 139: s = "\"descending\" expected"; break;
+ case 140: s = "\"orderby\" expected"; break;
+ case 141: s = "\"let\" expected"; break;
+ case 142: s = "\"join\" expected"; break;
+ case 143: s = "\"on\" expected"; break;
+ case 144: s = "\"equals\" expected"; break;
+ case 145: s = "??? expected"; break;
+ case 146: s = "invalid NamespaceMemberDecl"; break;
+ case 147: s = "invalid NonArrayType"; break;
+ case 148: s = "invalid Identifier"; break;
+ case 149: s = "invalid AttributeArgument"; break;
+ case 150: s = "invalid Expr"; break;
+ case 151: s = "invalid TypeModifier"; break;
+ case 152: s = "invalid TypeDecl"; break;
+ case 153: s = "invalid TypeDecl"; break;
+ case 154: s = "this symbol not expected in ClassBody"; break;
+ case 155: s = "this symbol not expected in InterfaceBody"; break;
+ case 156: s = "invalid IntegralType"; break;
+ case 157: s = "invalid ClassType"; break;
+ case 158: s = "invalid ClassMemberDecl"; break;
+ case 159: s = "invalid ClassMemberDecl"; break;
+ case 160: s = "invalid StructMemberDecl"; break;
+ case 161: s = "invalid StructMemberDecl"; break;
+ case 162: s = "invalid StructMemberDecl"; break;
+ case 163: s = "invalid StructMemberDecl"; break;
+ case 164: s = "invalid StructMemberDecl"; break;
+ case 165: s = "invalid StructMemberDecl"; break;
+ case 166: s = "invalid StructMemberDecl"; break;
+ case 167: s = "invalid StructMemberDecl"; break;
+ case 168: s = "invalid StructMemberDecl"; break;
+ case 169: s = "invalid StructMemberDecl"; break;
+ case 170: s = "invalid StructMemberDecl"; break;
+ case 171: s = "invalid StructMemberDecl"; break;
+ case 172: s = "invalid StructMemberDecl"; break;
+ case 173: s = "invalid InterfaceMemberDecl"; break;
+ case 174: s = "invalid InterfaceMemberDecl"; break;
+ case 175: s = "invalid InterfaceMemberDecl"; break;
+ case 176: s = "invalid TypeWithRestriction"; break;
+ case 177: s = "invalid TypeWithRestriction"; break;
+ case 178: s = "invalid SimpleType"; break;
+ case 179: s = "invalid AccessorModifiers"; break;
+ case 180: s = "this symbol not expected in Block"; break;
+ case 181: s = "invalid EventAccessorDecls"; break;
+ case 182: s = "invalid ConstructorInitializer"; break;
+ case 183: s = "invalid OverloadableOperator"; break;
+ case 184: s = "invalid AccessorDecls"; break;
+ case 185: s = "invalid InterfaceAccessors"; break;
+ case 186: s = "invalid InterfaceAccessors"; break;
+ case 187: s = "invalid GetAccessorDecl"; break;
+ case 188: s = "invalid SetAccessorDecl"; break;
+ case 189: s = "invalid VariableInitializer"; break;
+ case 190: s = "this symbol not expected in Statement"; break;
+ case 191: s = "invalid Statement"; break;
+ case 192: s = "invalid Argument"; break;
+ case 193: s = "invalid AssignmentOperator"; break;
+ case 194: s = "invalid ObjectPropertyInitializerOrVariableInitializer"; break;
+ case 195: s = "invalid ObjectPropertyInitializerOrVariableInitializer"; break;
+ case 196: s = "invalid EmbeddedStatement"; break;
+ case 197: s = "invalid EmbeddedStatement"; break;
+ case 198: s = "this symbol not expected in EmbeddedStatement"; break;
+ case 199: s = "invalid EmbeddedStatement"; break;
+ case 200: s = "invalid ForInitializer"; break;
+ case 201: s = "invalid GotoStatement"; break;
+ case 202: s = "invalid ResourceAcquisition"; break;
+ case 203: s = "invalid SwitchLabel"; break;
+ case 204: s = "invalid CatchClause"; break;
+ case 205: s = "invalid UnaryExpr"; break;
+ case 206: s = "invalid PrimaryExpr"; break;
+ case 207: s = "invalid PrimaryExpr"; break;
+ case 208: s = "invalid TypeArgumentList"; break;
+ case 209: s = "invalid NewExpression"; break;
+ case 210: s = "invalid NewExpression"; break;
+ case 211: s = "invalid LambdaExpressionParameter"; break;
+ case 212: s = "invalid LambdaExpressionBody"; break;
+ case 213: s = "invalid RelationalExpr"; break;
+ case 214: s = "invalid RelationalExpr"; break;
+ case 215: s = "invalid TypeParameterConstraintsClauseBase"; break;
+ case 216: s = "invalid QueryExpressionBody"; break;
+
+ default: s = "error " + errorNumber; break;
+ }
+ this.Errors.Error(line, col, s);
}
-
- static bool[,] set = {
- {T,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,T,T,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,x, T,T,T,T, T,x,T,T, T,T,T,T, T,x,T,T, T,x,T,T, x,T,T,T, x,x,T,x, T,T,T,T, x,T,T,T, T,T,x,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, T,T,x,x, x,x,x,x, T,T,T,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,T,x,x, x,x,x,x, T,T,T,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,T,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,T,x, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,x,T, T,T,T,T, T,T,x,T, T,T,T,T, T,T,T,T, T,T,T,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,T,T,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,T,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,T,x,T, x,x,x,x, T,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,x,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,x,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,x,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,x,x, x,x,T,x, T,T,T,T, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,T,T, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,T,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,x, x,T,T,x, T,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,T,x, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,T,x,x, x,x,x,x, T,x,T,x, T,T,x,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {T,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,x, x,T,T,x, T,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,x, x,T,T,x, x,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,T,x, T,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,x,x,x, x,x,x,x, x,x,T,x, T,T,T,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,T, x,T,T,x, T,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,x,x, T,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,T,x,x, T,T,T,x, x,x,x}
-
- };
- string ErrorDesc(int errorNumber)
+ private bool StartOf(int s)
{
- switch (errorNumber) {
- case 0: return "EOF expected";
- case 1: return "ident expected";
- case 2: return "Literal expected";
- case 3: return "\"=\" expected";
- case 4: return "\"+\" expected";
- case 5: return "\"-\" expected";
- case 6: return "\"*\" expected";
- case 7: return "\"/\" expected";
- case 8: return "\"%\" expected";
- case 9: return "\":\" expected";
- case 10: return "\"::\" expected";
- case 11: return "\";\" expected";
- case 12: return "\"?\" expected";
- case 13: return "\"??\" expected";
- case 14: return "\",\" expected";
- case 15: return "\".\" expected";
- case 16: return "\"{\" expected";
- case 17: return "\"}\" expected";
- case 18: return "\"[\" expected";
- case 19: return "\"]\" expected";
- case 20: return "\"(\" expected";
- case 21: return "\")\" expected";
- case 22: return "\">\" expected";
- case 23: return "\"<\" expected";
- case 24: return "\"!\" expected";
- case 25: return "\"&&\" expected";
- case 26: return "\"||\" expected";
- case 27: return "\"~\" expected";
- case 28: return "\"&\" expected";
- case 29: return "\"|\" expected";
- case 30: return "\"^\" expected";
- case 31: return "\"++\" expected";
- case 32: return "\"--\" expected";
- case 33: return "\"==\" expected";
- case 34: return "\"!=\" expected";
- case 35: return "\">=\" expected";
- case 36: return "\"<=\" expected";
- case 37: return "\"<<\" expected";
- case 38: return "\"+=\" expected";
- case 39: return "\"-=\" expected";
- case 40: return "\"*=\" expected";
- case 41: return "\"/=\" expected";
- case 42: return "\"%=\" expected";
- case 43: return "\"&=\" expected";
- case 44: return "\"|=\" expected";
- case 45: return "\"^=\" expected";
- case 46: return "\"<<=\" expected";
- case 47: return "\"->\" expected";
- case 48: return "\"=>\" expected";
- case 49: return "\"abstract\" expected";
- case 50: return "\"as\" expected";
- case 51: return "\"base\" expected";
- case 52: return "\"bool\" expected";
- case 53: return "\"break\" expected";
- case 54: return "\"byte\" expected";
- case 55: return "\"case\" expected";
- case 56: return "\"catch\" expected";
- case 57: return "\"char\" expected";
- case 58: return "\"checked\" expected";
- case 59: return "\"class\" expected";
- case 60: return "\"const\" expected";
- case 61: return "\"continue\" expected";
- case 62: return "\"decimal\" expected";
- case 63: return "\"default\" expected";
- case 64: return "\"delegate\" expected";
- case 65: return "\"do\" expected";
- case 66: return "\"double\" expected";
- case 67: return "\"else\" expected";
- case 68: return "\"enum\" expected";
- case 69: return "\"event\" expected";
- case 70: return "\"explicit\" expected";
- case 71: return "\"extern\" expected";
- case 72: return "\"false\" expected";
- case 73: return "\"finally\" expected";
- case 74: return "\"fixed\" expected";
- case 75: return "\"float\" expected";
- case 76: return "\"for\" expected";
- case 77: return "\"foreach\" expected";
- case 78: return "\"goto\" expected";
- case 79: return "\"if\" expected";
- case 80: return "\"implicit\" expected";
- case 81: return "\"in\" expected";
- case 82: return "\"int\" expected";
- case 83: return "\"interface\" expected";
- case 84: return "\"internal\" expected";
- case 85: return "\"is\" expected";
- case 86: return "\"lock\" expected";
- case 87: return "\"long\" expected";
- case 88: return "\"namespace\" expected";
- case 89: return "\"new\" expected";
- case 90: return "\"null\" expected";
- case 91: return "\"object\" expected";
- case 92: return "\"operator\" expected";
- case 93: return "\"out\" expected";
- case 94: return "\"override\" expected";
- case 95: return "\"params\" expected";
- case 96: return "\"private\" expected";
- case 97: return "\"protected\" expected";
- case 98: return "\"public\" expected";
- case 99: return "\"readonly\" expected";
- case 100: return "\"ref\" expected";
- case 101: return "\"return\" expected";
- case 102: return "\"sbyte\" expected";
- case 103: return "\"sealed\" expected";
- case 104: return "\"short\" expected";
- case 105: return "\"sizeof\" expected";
- case 106: return "\"stackalloc\" expected";
- case 107: return "\"static\" expected";
- case 108: return "\"string\" expected";
- case 109: return "\"struct\" expected";
- case 110: return "\"switch\" expected";
- case 111: return "\"this\" expected";
- case 112: return "\"throw\" expected";
- case 113: return "\"true\" expected";
- case 114: return "\"try\" expected";
- case 115: return "\"typeof\" expected";
- case 116: return "\"uint\" expected";
- case 117: return "\"ulong\" expected";
- case 118: return "\"unchecked\" expected";
- case 119: return "\"unsafe\" expected";
- case 120: return "\"ushort\" expected";
- case 121: return "\"using\" expected";
- case 122: return "\"virtual\" expected";
- case 123: return "\"void\" expected";
- case 124: return "\"volatile\" expected";
- case 125: return "\"while\" expected";
- case 126: return "\"partial\" expected";
- case 127: return "\"where\" expected";
- case 128: return "\"get\" expected";
- case 129: return "\"set\" expected";
- case 130: return "\"add\" expected";
- case 131: return "\"remove\" expected";
- case 132: return "\"yield\" expected";
- case 133: return "\"select\" expected";
- case 134: return "\"group\" expected";
- case 135: return "\"by\" expected";
- case 136: return "\"into\" expected";
- case 137: return "\"from\" expected";
- case 138: return "\"ascending\" expected";
- case 139: return "\"descending\" expected";
- case 140: return "\"orderby\" expected";
- case 141: return "\"let\" expected";
- case 142: return "\"join\" expected";
- case 143: return "\"on\" expected";
- case 144: return "\"equals\" expected";
- case 145: return "??? expected";
- case 146: return "invalid NamespaceMemberDecl";
- case 147: return "invalid NonArrayType";
- case 148: return "invalid Identifier";
- case 149: return "invalid AttributeArgument";
- case 150: return "invalid Expr";
- case 151: return "invalid AttributeSection";
- case 152: return "invalid TypeModifier";
- case 153: return "invalid TypeDecl";
- case 154: return "invalid TypeDecl";
- case 155: return "this symbol not expected in ClassBody";
- case 156: return "this symbol not expected in InterfaceBody";
- case 157: return "invalid IntegralType";
- case 158: return "invalid ClassType";
- case 159: return "invalid ClassMemberDecl";
- case 160: return "invalid ClassMemberDecl";
- case 161: return "invalid StructMemberDecl";
- case 162: return "invalid StructMemberDecl";
- case 163: return "invalid StructMemberDecl";
- case 164: return "invalid StructMemberDecl";
- case 165: return "invalid StructMemberDecl";
- case 166: return "invalid StructMemberDecl";
- case 167: return "invalid StructMemberDecl";
- case 168: return "invalid StructMemberDecl";
- case 169: return "invalid StructMemberDecl";
- case 170: return "invalid StructMemberDecl";
- case 171: return "invalid StructMemberDecl";
- case 172: return "invalid StructMemberDecl";
- case 173: return "invalid StructMemberDecl";
- case 174: return "invalid InterfaceMemberDecl";
- case 175: return "invalid InterfaceMemberDecl";
- case 176: return "invalid InterfaceMemberDecl";
- case 177: return "invalid TypeWithRestriction";
- case 178: return "invalid TypeWithRestriction";
- case 179: return "invalid SimpleType";
- case 180: return "invalid AccessorModifiers";
- case 181: return "this symbol not expected in Block";
- case 182: return "invalid EventAccessorDecls";
- case 183: return "invalid ConstructorInitializer";
- case 184: return "invalid OverloadableOperator";
- case 185: return "invalid AccessorDecls";
- case 186: return "invalid InterfaceAccessors";
- case 187: return "invalid InterfaceAccessors";
- case 188: return "invalid GetAccessorDecl";
- case 189: return "invalid SetAccessorDecl";
- case 190: return "invalid VariableInitializer";
- case 191: return "this symbol not expected in Statement";
- case 192: return "invalid Statement";
- case 193: return "invalid Argument";
- case 194: return "invalid AssignmentOperator";
- case 195: return "invalid ObjectPropertyInitializerOrVariableInitializer";
- case 196: return "invalid ObjectPropertyInitializerOrVariableInitializer";
- case 197: return "invalid EmbeddedStatement";
- case 198: return "invalid EmbeddedStatement";
- case 199: return "this symbol not expected in EmbeddedStatement";
- case 200: return "invalid EmbeddedStatement";
- case 201: return "invalid ForInitializer";
- case 202: return "invalid GotoStatement";
- case 203: return "invalid ResourceAcquisition";
- case 204: return "invalid SwitchLabel";
- case 205: return "invalid CatchClause";
- case 206: return "invalid UnaryExpr";
- case 207: return "invalid PrimaryExpr";
- case 208: return "invalid PrimaryExpr";
- case 209: return "invalid TypeArgumentList";
- case 210: return "invalid NewExpression";
- case 211: return "invalid NewExpression";
- case 212: return "invalid LambdaExpressionParameter";
- case 213: return "invalid LambdaExpressionBody";
- case 214: return "invalid TypeParameterConstraintsClauseBase";
- case 215: return "invalid QueryExpressionBody";
-
- default: return "error " + errorNumber;
- }
+ return set[s, lexer.LookAhead.kind];
}
+
+ static bool[,] set = {
+ {T,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,T,T,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,x, T,T,T,T, T,x,T,T, T,T,T,T, T,x,T,T, T,x,T,T, x,T,T,T, x,x,T,x, T,T,T,T, x,T,T,T, T,T,x,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, T,T,x,x, x,x,x,x, T,T,T,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,T,x,x, x,x,x,x, T,T,T,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,T,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,T,x, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,x,T, T,T,T,T, T,T,x,T, T,T,T,T, T,T,T,T, T,T,T,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,T,T,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,T,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,T,x,T, x,x,x,x, T,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,x,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,x,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,T, x,x,T,T, x,x,x,x, T,x,T,T, T,x,x,T, x,T,x,T, x,x,T,x, T,T,T,T, x,x,T,T, T,x,x,T, T,T,x,x, x,x,x,x, T,T,x,T, T,x,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,x,x, x,x,T,x, T,T,T,T, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,T, T,x,T,x, T,x,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,T,T, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,T,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,x, x,T,T,x, T,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,T,x, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,T,x,x, x,x,x,x, T,x,T,x, T,T,x,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {T,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,x, x,T,T,x, T,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,x, x,T,T,x, x,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,T,x, T,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,x,x,x, x,x,x,x, x,x,T,x, T,T,T,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,T,T,x, T,T,T,x, x,x,x,T, x,x,x,x, T,x,x,x, T,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,T, x,T,T,x, T,T,T,T, T,T,T,x, x,x,x,x, T,x,T,T, T,T,T,T, x,x,T,x, x,x,T,T, x,T,T,T, x,x,x,x, x,x,x,x, x,T,T,x, T,T,x,x, T,x,T,T, T,T,T,T, T,T,T,T, T,T,x,T, x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, T,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,T,x, x,T,T,x, x,x,T,T, T,x,T,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,T,T, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, T,x,x,T, x,T,x,T, T,T,T,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,x,x, T,x,T,x, T,x,x,x, T,x,x,x, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,T,x,x, T,T,T,x, x,x,x}
+ };
} // end Parser
-} // end namespace
+}
\ No newline at end of file
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.atg b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.atg
index 0ba739573d..5cede5e978 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.atg
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.atg
@@ -22,6 +22,12 @@ TOKENS
LiteralSingle
LiteralDecimal
LiteralDate
+ XmlOpenTag
+ XmlCloseTag
+ XmlStartInlineVB
+ XmlEndInlineVB
+ XmlCloseTagEmptyElement
+ XmlOpenEndTag
/* ----- special character ----- */
"="
@@ -150,6 +156,7 @@ TOKENS
"Is"
"IsNot"
"Join"
+ "Key"
"Let"
"Lib"
"Like"
@@ -326,23 +333,17 @@ Block =
.
Expression =
- (. isExpressionStart = true; .)
+ (. nextTokenIsPotentialStartOfXmlMode = true; .)
(
- Literal (. isExpressionStart = false; .) |
- ( "(" (. isExpressionStart = false; .) Expression ")" ) |
- ( Identifier (. isExpressionStart = false; .) [ "(" "Of" TypeName { "," TypeName } ")" ] ) |
- ( "AddressOf" (. isExpressionStart = false; .) Expression) |
+ Literal |
+ ( "(" Expression ")" ) |
+ ( Identifier [ "(" "Of" TypeName { "," TypeName } ")" ] ) |
+ ( "AddressOf" Expression) |
( "<" (. PushContext(Context.Xml); .) ANY ">" (. PopContext(); .) )
)
.
-/*
-XmlLiteralExpression =
- "<"
- ( "!" | "?" )
-.*/
-
PrimitiveTypeName =
"Byte" |
"SByte" |
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.cs b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.cs
index aa81b74f5d..d54b7a359e 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.cs
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.cs
@@ -7,6 +7,7 @@
using System;
using System.Collections.Generic;
+using System.Linq;
using System.Text;
namespace ICSharpCode.NRefactory.Parser.VBNet.Experimental
@@ -15,7 +16,6 @@ namespace ICSharpCode.NRefactory.Parser.VBNet.Experimental
{
Stack stack = new Stack();
StringBuilder output = new StringBuilder();
- bool isExpressionStart = false;
void PopContext()
{
@@ -50,9 +50,18 @@ namespace ICSharpCode.NRefactory.Parser.VBNet.Experimental
public string Output {
get { return output.ToString(); }
}
+
+ public Context CurrentContext {
+ get { return stack.Any() ? stack.Peek() : Context.Global; }
+ }
+
+ public bool NextTokenIsPotentialStartOfXmlMode {
+ get { return nextTokenIsPotentialStartOfXmlMode; }
+ }
}
- public enum Context {
+ public enum Context
+ {
Global,
Type,
Member,
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Parser.cs b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Parser.cs
index fd45a72184..433ca219f8 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Parser.cs
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Parser.cs
@@ -55,7 +55,7 @@ int currentState = 1;
goto case 15; // OptionStatement
}
case 3: {
- if (t.kind == 159) {
+ if (t.kind == 166) {
goto case 2;
} else {
goto case 5;
@@ -66,7 +66,7 @@ int currentState = 1;
goto case 19; // ImportsStatement
}
case 5: {
- if (t.kind == 124) {
+ if (t.kind == 130) {
goto case 4;
} else {
goto case 7;
@@ -77,7 +77,7 @@ int currentState = 1;
goto case 24; // AttributeBlock
}
case 7: {
- if (t.kind == 28) {
+ if (t.kind == 34) {
goto case 6;
} else {
goto case 9;
@@ -105,7 +105,7 @@ int currentState = 1;
break;
}
case 12: {
- Expect(11, t); // ":"
+ Expect(17, t); // ":"
currentState = stateStack.Pop();
break;
}
@@ -117,7 +117,7 @@ int currentState = 1;
}
}
case 14: {
- if (t.kind == 11) {
+ if (t.kind == 17) {
goto case 12;
} else {
Error(t);
@@ -126,7 +126,7 @@ int currentState = 1;
}
}
case 15: { // start of OptionStatement
- Expect(159, t); // "Option"
+ Expect(166, t); // "Option"
currentState = 17;
break;
}
@@ -145,7 +145,7 @@ int currentState = 1;
goto case 13; // StatementTerminator
}
case 19: { // start of ImportsStatement
- Expect(124, t); // "Imports"
+ Expect(130, t); // "Imports"
currentState = 20;
break;
}
@@ -168,7 +168,7 @@ int currentState = 1;
goto case 13; // StatementTerminator
}
case 24: { // start of AttributeBlock
- Expect(28, t); // "<"
+ Expect(34, t); // "<"
currentState = 25;
break;
}
@@ -188,7 +188,7 @@ int currentState = 1;
}
}
case 28: {
- Expect(27, t); // ">"
+ Expect(33, t); // ">"
currentState = 29;
break;
}
@@ -216,7 +216,7 @@ int currentState = 1;
goto case 46; // TypeDeclaration
}
case 34: { // start of NamespaceMemberDeclaration
- if (t.kind == 146) {
+ if (t.kind == 153) {
goto case 32;
} else {
goto case 35;
@@ -232,7 +232,7 @@ int currentState = 1;
}
}
case 36: { // start of NamespaceDeclaration
- Expect(146, t); // "Namespace"
+ Expect(153, t); // "Namespace"
currentState = 38;
break;
}
@@ -263,12 +263,12 @@ int currentState = 1;
}
}
case 42: {
- Expect(100, t); // "End"
+ Expect(106, t); // "End"
currentState = 43;
break;
}
case 43: {
- Expect(146, t); // "Namespace"
+ Expect(153, t); // "Namespace"
currentState = 44;
break;
}
@@ -280,7 +280,7 @@ int currentState = 1;
goto case 24; // AttributeBlock
}
case 46: { // start of TypeDeclaration
- if (t.kind == 28) {
+ if (t.kind == 34) {
goto case 45;
} else {
goto case 48;
@@ -288,7 +288,7 @@ int currentState = 1;
}
case 47: {
stateStack.Push(48);
- goto case 357; // TypeModifier
+ goto case 353; // TypeModifier
}
case 48: {
if (set[5, t.kind]) {
@@ -298,24 +298,24 @@ int currentState = 1;
}
}
case 49: {
- Expect(141, t); // "Module"
+ Expect(148, t); // "Module"
currentState = 54;
break;
}
case 50: {
- Expect(71, t); // "Class"
+ Expect(77, t); // "Class"
currentState = 54;
break;
}
case 51: {
- if (t.kind == 141) {
+ if (t.kind == 148) {
goto case 49;
} else {
goto case 52;
}
}
case 52: {
- if (t.kind == 71) {
+ if (t.kind == 77) {
goto case 50;
} else {
Error(t);
@@ -353,29 +353,29 @@ int currentState = 1;
}
}
case 59: {
- Expect(100, t); // "End"
+ Expect(106, t); // "End"
currentState = 62;
break;
}
case 60: {
- Expect(141, t); // "Module"
+ Expect(148, t); // "Module"
currentState = 64;
break;
}
case 61: {
- Expect(71, t); // "Class"
+ Expect(77, t); // "Class"
currentState = 64;
break;
}
case 62: {
- if (t.kind == 141) {
+ if (t.kind == 148) {
goto case 60;
} else {
goto case 63;
}
}
case 63: {
- if (t.kind == 71) {
+ if (t.kind == 77) {
goto case 61;
} else {
Error(t);
@@ -400,7 +400,7 @@ int currentState = 1;
goto case 24; // AttributeBlock
}
case 68: {
- if (t.kind == 28) {
+ if (t.kind == 34) {
goto case 67;
} else {
goto case 70;
@@ -408,7 +408,7 @@ int currentState = 1;
}
case 69: {
stateStack.Push(70);
- goto case 361; // MemberModifier
+ goto case 357; // MemberModifier
}
case 70: {
if (set[7, t.kind]) {
@@ -433,7 +433,7 @@ int currentState = 1;
}
}
case 74: {
- if (t.kind == 114 || t.kind == 195) {
+ if (t.kind == 120 || t.kind == 202) {
goto case 72;
} else {
Error(t);
@@ -446,24 +446,24 @@ int currentState = 1;
goto switchlbl;
}
case 76: {
- Expect(195, t); // "Sub"
+ Expect(202, t); // "Sub"
currentState = 80;
break;
}
case 77: {
- Expect(114, t); // "Function"
+ Expect(120, t); // "Function"
currentState = 80;
break;
}
case 78: { // start of SubOrFunctionDeclaration
- if (t.kind == 195) {
+ if (t.kind == 202) {
goto case 76;
} else {
goto case 79;
}
}
case 79: {
- if (t.kind == 114) {
+ if (t.kind == 120) {
goto case 77;
} else {
Error(t);
@@ -483,7 +483,7 @@ int currentState = 1;
goto case 87;
}
case 83: {
- Expect(25, t); // "("
+ Expect(31, t); // "("
currentState = 85;
break;
}
@@ -499,28 +499,28 @@ int currentState = 1;
}
}
case 86: {
- Expect(26, t); // ")"
+ Expect(32, t); // ")"
currentState = 90;
break;
}
case 87: {
- if (t.kind == 25) {
+ if (t.kind == 31) {
goto case 83;
} else {
goto case 90;
}
}
case 88: {
- Expect(50, t); // "As"
+ Expect(56, t); // "As"
currentState = 89;
break;
}
case 89: {
stateStack.Push(91);
- goto case 196; // TypeName
+ goto case 192; // TypeName
}
case 90: {
- if (t.kind == 50) {
+ if (t.kind == 56) {
goto case 88;
} else {
goto case 91;
@@ -531,29 +531,29 @@ int currentState = 1;
goto case 123; // Block
}
case 92: {
- Expect(100, t); // "End"
+ Expect(106, t); // "End"
currentState = 95;
break;
}
case 93: {
- Expect(195, t); // "Sub"
+ Expect(202, t); // "Sub"
currentState = 97;
break;
}
case 94: {
- Expect(114, t); // "Function"
+ Expect(120, t); // "Function"
currentState = 97;
break;
}
case 95: {
- if (t.kind == 195) {
+ if (t.kind == 202) {
goto case 93;
} else {
goto case 96;
}
}
case 96: {
- if (t.kind == 114) {
+ if (t.kind == 120) {
goto case 94;
} else {
Error(t);
@@ -564,12 +564,12 @@ int currentState = 1;
goto case 13; // StatementTerminator
}
case 98: {
- Expect(75, t); // "Const"
+ Expect(81, t); // "Const"
currentState = 100;
break;
}
case 99: { // start of MemberVariableOrConstantDeclaration
- if (t.kind == 75) {
+ if (t.kind == 81) {
goto case 98;
} else {
goto case 100;
@@ -577,26 +577,26 @@ int currentState = 1;
}
case 100: {
stateStack.Push(103);
- goto case 287; // Identifier
+ goto case 283; // Identifier
}
case 101: {
- Expect(50, t); // "As"
+ Expect(56, t); // "As"
currentState = 102;
break;
}
case 102: {
stateStack.Push(106);
- goto case 196; // TypeName
+ goto case 192; // TypeName
}
case 103: {
- if (t.kind == 50) {
+ if (t.kind == 56) {
goto case 101;
} else {
goto case 106;
}
}
case 104: {
- Expect(10, t); // "="
+ Expect(16, t); // "="
currentState = 105;
break;
}
@@ -605,7 +605,7 @@ int currentState = 1;
goto case 132; // Expression
}
case 106: {
- if (t.kind == 10) {
+ if (t.kind == 16) {
goto case 104;
} else {
goto case 107;
@@ -619,7 +619,7 @@ int currentState = 1;
goto case 113; // Parameter
}
case 109: {
- Expect(12, t); // ","
+ Expect(18, t); // ","
currentState = 110;
break;
}
@@ -628,7 +628,7 @@ int currentState = 1;
goto case 113; // Parameter
}
case 111: {
- if (t.kind == 12) {
+ if (t.kind == 18) {
goto case 109;
} else {
currentState = stateStack.Pop();
@@ -640,7 +640,7 @@ int currentState = 1;
goto case 24; // AttributeBlock
}
case 113: { // start of Parameter
- if (t.kind == 28) {
+ if (t.kind == 34) {
goto case 112;
} else {
goto case 115;
@@ -648,7 +648,7 @@ int currentState = 1;
}
case 114: {
stateStack.Push(115);
- goto case 381; // ParameterModifier
+ goto case 377; // ParameterModifier
}
case 115: {
if (set[10, t.kind]) {
@@ -659,26 +659,26 @@ int currentState = 1;
}
case 116: {
stateStack.Push(119);
- goto case 287; // Identifier
+ goto case 283; // Identifier
}
case 117: {
- Expect(50, t); // "As"
+ Expect(56, t); // "As"
currentState = 118;
break;
}
case 118: {
stateStack.Push(122);
- goto case 196; // TypeName
+ goto case 192; // TypeName
}
case 119: {
- if (t.kind == 50) {
+ if (t.kind == 56) {
goto case 117;
} else {
goto case 122;
}
}
case 120: {
- Expect(10, t); // "="
+ Expect(16, t); // "="
currentState = 121;
break;
}
@@ -686,7 +686,7 @@ int currentState = 1;
goto case 132; // Expression
}
case 122: {
- if (t.kind == 10) {
+ if (t.kind == 16) {
goto case 120;
} else {
currentState = stateStack.Pop();
@@ -706,7 +706,7 @@ int currentState = 1;
goto case 13; // StatementTerminator
}
case 126: {
- if (t.kind == 1 || t.kind == 11) {
+ if (t.kind == 1 || t.kind == 17) {
goto case 125;
} else {
goto case 128;
@@ -714,7 +714,7 @@ int currentState = 1;
}
case 127: {
stateStack.Push(128);
- goto case 285; // Statement
+ goto case 281; // Statement
}
case 128: {
if (set[11, t.kind]) {
@@ -728,7 +728,7 @@ int currentState = 1;
goto case 13; // StatementTerminator
}
case 130: {
- if (t.kind == 1 || t.kind == 11) {
+ if (t.kind == 1 || t.kind == 17) {
goto case 129;
} else {
goto case 131;
@@ -740,603 +740,609 @@ int currentState = 1;
goto switchlbl;
}
case 132: { // start of Expression
- isExpressionStart = true;
- goto case 139;
+ nextTokenIsPotentialStartOfXmlMode = true;
+ goto case 137;
}
case 133: {
- stateStack.Push(134);
- goto case 221; // Literal
+ goto case 217; // Literal
}
case 134: {
- isExpressionStart = false;
- currentState = stateStack.Pop();
- goto switchlbl;
- }
- case 135: {
- Expect(25, t); // "("
- currentState = 136;
+ Expect(31, t); // "("
+ currentState = 135;
break;
}
- case 136: {
- isExpressionStart = false;
- goto case 137;
- }
- case 137: {
- stateStack.Push(138);
+ case 135: {
+ stateStack.Push(136);
goto case 132; // Expression
}
- case 138: {
- Expect(26, t); // ")"
+ case 136: {
+ Expect(32, t); // ")"
currentState = stateStack.Pop();
break;
}
- case 139: {
+ case 137: {
if (set[12, t.kind]) {
goto case 133;
} else {
- goto case 140;
+ goto case 138;
}
}
- case 140: {
- if (t.kind == 25) {
- goto case 135;
+ case 138: {
+ if (t.kind == 31) {
+ goto case 134;
} else {
- goto case 151;
+ goto case 148;
}
}
+ case 139: {
+ stateStack.Push(147);
+ goto case 283; // Identifier
+ }
+ case 140: {
+ Expect(31, t); // "("
+ currentState = 141;
+ break;
+ }
case 141: {
- stateStack.Push(142);
- goto case 287; // Identifier
+ Expect(162, t); // "Of"
+ currentState = 142;
+ break;
}
case 142: {
- isExpressionStart = false;
- goto case 150;
+ stateStack.Push(145);
+ goto case 192; // TypeName
}
case 143: {
- Expect(25, t); // "("
+ Expect(18, t); // ","
currentState = 144;
break;
}
case 144: {
- Expect(155, t); // "Of"
- currentState = 145;
- break;
+ stateStack.Push(145);
+ goto case 192; // TypeName
}
case 145: {
- stateStack.Push(148);
- goto case 196; // TypeName
+ if (t.kind == 18) {
+ goto case 143;
+ } else {
+ goto case 146;
+ }
}
case 146: {
- Expect(12, t); // ","
- currentState = 147;
+ Expect(32, t); // ")"
+ currentState = stateStack.Pop();
break;
}
case 147: {
- stateStack.Push(148);
- goto case 196; // TypeName
+ if (t.kind == 31) {
+ goto case 140;
+ } else {
+ currentState = stateStack.Pop();
+ goto switchlbl;
+ }
}
case 148: {
- if (t.kind == 12) {
- goto case 146;
+ if (set[13, t.kind]) {
+ goto case 139;
} else {
- goto case 149;
+ goto case 151;
}
}
case 149: {
- Expect(26, t); // ")"
- currentState = stateStack.Pop();
+ Expect(50, t); // "AddressOf"
+ currentState = 150;
break;
}
case 150: {
- if (t.kind == 25) {
- goto case 143;
- } else {
- currentState = stateStack.Pop();
- goto switchlbl;
- }
+ goto case 132; // Expression
}
case 151: {
- if (set[13, t.kind]) {
- goto case 141;
+ if (t.kind == 50) {
+ goto case 149;
} else {
- goto case 155;
+ goto case 157;
}
}
case 152: {
- Expect(44, t); // "AddressOf"
+ Expect(34, t); // "<"
currentState = 153;
break;
}
case 153: {
- isExpressionStart = false;
+ PushContext(Context.Xml);
goto case 154;
}
case 154: {
- goto case 132; // Expression
+ currentState = 155;
+ break;
}
case 155: {
- if (t.kind == 44) {
- goto case 152;
- } else {
- goto case 161;
- }
+ Expect(33, t); // ">"
+ currentState = 156;
+ break;
}
case 156: {
- Expect(28, t); // "<"
- currentState = 157;
- break;
+ PopContext();
+ currentState = stateStack.Pop();
+ goto switchlbl;
}
case 157: {
- PushContext(Context.Xml);
- goto case 158;
+ if (t.kind == 34) {
+ goto case 152;
+ } else {
+ Error(t);
+ currentState = stateStack.Pop();
+ goto switchlbl;
+ }
}
case 158: {
- currentState = 159;
+ Expect(64, t); // "Byte"
+ currentState = stateStack.Pop();
break;
}
case 159: {
- Expect(27, t); // ">"
- currentState = 160;
+ Expect(188, t); // "SByte"
+ currentState = stateStack.Pop();
break;
}
- case 160: {
- PopContext();
- currentState = stateStack.Pop();
- goto switchlbl;
+ case 160: { // start of PrimitiveTypeName
+ if (t.kind == 64) {
+ goto case 158;
+ } else {
+ goto case 161;
+ }
}
case 161: {
- if (t.kind == 28) {
- goto case 156;
+ if (t.kind == 188) {
+ goto case 159;
} else {
- Error(t);
- currentState = stateStack.Pop();
- goto switchlbl;
+ goto case 163;
}
}
case 162: {
- Expect(58, t); // "Byte"
+ Expect(217, t); // "UShort"
currentState = stateStack.Pop();
break;
}
case 163: {
- Expect(181, t); // "SByte"
- currentState = stateStack.Pop();
- break;
- }
- case 164: { // start of PrimitiveTypeName
- if (t.kind == 58) {
+ if (t.kind == 217) {
goto case 162;
} else {
goto case 165;
}
}
+ case 164: {
+ Expect(193, t); // "Short"
+ currentState = stateStack.Pop();
+ break;
+ }
case 165: {
- if (t.kind == 181) {
- goto case 163;
+ if (t.kind == 193) {
+ goto case 164;
} else {
goto case 167;
}
}
case 166: {
- Expect(210, t); // "UShort"
+ Expect(213, t); // "UInteger"
currentState = stateStack.Pop();
break;
}
case 167: {
- if (t.kind == 210) {
+ if (t.kind == 213) {
goto case 166;
} else {
goto case 169;
}
}
case 168: {
- Expect(186, t); // "Short"
+ Expect(134, t); // "Integer"
currentState = stateStack.Pop();
break;
}
case 169: {
- if (t.kind == 186) {
+ if (t.kind == 134) {
goto case 168;
} else {
goto case 171;
}
}
case 170: {
- Expect(206, t); // "UInteger"
+ Expect(214, t); // "ULong"
currentState = stateStack.Pop();
break;
}
case 171: {
- if (t.kind == 206) {
+ if (t.kind == 214) {
goto case 170;
} else {
goto case 173;
}
}
case 172: {
- Expect(128, t); // "Integer"
+ Expect(144, t); // "Long"
currentState = stateStack.Pop();
break;
}
case 173: {
- if (t.kind == 128) {
+ if (t.kind == 144) {
goto case 172;
} else {
goto case 175;
}
}
case 174: {
- Expect(207, t); // "ULong"
+ Expect(194, t); // "Single"
currentState = stateStack.Pop();
break;
}
case 175: {
- if (t.kind == 207) {
+ if (t.kind == 194) {
goto case 174;
} else {
goto case 177;
}
}
case 176: {
- Expect(137, t); // "Long"
+ Expect(102, t); // "Double"
currentState = stateStack.Pop();
break;
}
case 177: {
- if (t.kind == 137) {
+ if (t.kind == 102) {
goto case 176;
} else {
goto case 179;
}
}
case 178: {
- Expect(187, t); // "Single"
+ Expect(93, t); // "Decimal"
currentState = stateStack.Pop();
break;
}
case 179: {
- if (t.kind == 187) {
+ if (t.kind == 93) {
goto case 178;
} else {
goto case 181;
}
}
case 180: {
- Expect(96, t); // "Double"
+ Expect(61, t); // "Boolean"
currentState = stateStack.Pop();
break;
}
case 181: {
- if (t.kind == 96) {
+ if (t.kind == 61) {
goto case 180;
} else {
goto case 183;
}
}
case 182: {
- Expect(87, t); // "Decimal"
+ Expect(92, t); // "Date"
currentState = stateStack.Pop();
break;
}
case 183: {
- if (t.kind == 87) {
+ if (t.kind == 92) {
goto case 182;
} else {
goto case 185;
}
}
case 184: {
- Expect(55, t); // "Boolean"
+ Expect(75, t); // "Char"
currentState = stateStack.Pop();
break;
}
case 185: {
- if (t.kind == 55) {
+ if (t.kind == 75) {
goto case 184;
} else {
goto case 187;
}
}
case 186: {
- Expect(86, t); // "Date"
+ Expect(200, t); // "String"
currentState = stateStack.Pop();
break;
}
case 187: {
- if (t.kind == 86) {
+ if (t.kind == 200) {
goto case 186;
} else {
goto case 189;
}
}
case 188: {
- Expect(69, t); // "Char"
+ Expect(161, t); // "Object"
currentState = stateStack.Pop();
break;
}
case 189: {
- if (t.kind == 69) {
+ if (t.kind == 161) {
goto case 188;
} else {
- goto case 191;
+ Error(t);
+ currentState = stateStack.Pop();
+ goto switchlbl;
}
}
case 190: {
- Expect(193, t); // "String"
- currentState = stateStack.Pop();
+ Expect(123, t); // "Global"
+ currentState = 197;
break;
}
case 191: {
- if (t.kind == 193) {
+ stateStack.Push(197);
+ goto case 283; // Identifier
+ }
+ case 192: { // start of TypeName
+ if (t.kind == 123) {
goto case 190;
} else {
goto case 193;
}
}
- case 192: {
- Expect(154, t); // "Object"
- currentState = stateStack.Pop();
- break;
- }
case 193: {
- if (t.kind == 154) {
- goto case 192;
+ if (set[13, t.kind]) {
+ goto case 191;
} else {
- Error(t);
- currentState = stateStack.Pop();
- goto switchlbl;
+ goto case 195;
}
}
case 194: {
- Expect(117, t); // "Global"
- currentState = 201;
- break;
+ stateStack.Push(197);
+ goto case 160; // PrimitiveTypeName
}
case 195: {
- stateStack.Push(201);
- goto case 287; // Identifier
- }
- case 196: { // start of TypeName
- if (t.kind == 117) {
+ if (set[14, t.kind]) {
goto case 194;
} else {
+ Error(t);
goto case 197;
}
}
+ case 196: {
+ stateStack.Push(197);
+ goto case 203; // TypeSuffix
+ }
case 197: {
- if (set[13, t.kind]) {
- goto case 195;
+ if (t.kind == 31) {
+ goto case 196;
} else {
- goto case 199;
+ goto case 202;
}
}
case 198: {
- stateStack.Push(201);
- goto case 164; // PrimitiveTypeName
+ Expect(22, t); // "."
+ currentState = 199;
+ break;
}
case 199: {
- if (set[14, t.kind]) {
- goto case 198;
- } else {
- Error(t);
- goto case 201;
- }
+ stateStack.Push(201);
+ goto case 214; // IdentifierOrKeyword
}
case 200: {
stateStack.Push(201);
- goto case 207; // TypeSuffix
+ goto case 203; // TypeSuffix
}
case 201: {
- if (t.kind == 25) {
+ if (t.kind == 31) {
goto case 200;
} else {
- goto case 206;
+ goto case 202;
}
}
case 202: {
- Expect(16, t); // "."
- currentState = 203;
- break;
- }
- case 203: {
- stateStack.Push(205);
- goto case 218; // IdentifierOrKeyword
- }
- case 204: {
- stateStack.Push(205);
- goto case 207; // TypeSuffix
- }
- case 205: {
- if (t.kind == 25) {
- goto case 204;
- } else {
- goto case 206;
- }
- }
- case 206: {
- if (t.kind == 16) {
- goto case 202;
+ if (t.kind == 22) {
+ goto case 198;
} else {
currentState = stateStack.Pop();
goto switchlbl;
}
}
- case 207: { // start of TypeSuffix
- Expect(25, t); // "("
- currentState = 215;
+ case 203: { // start of TypeSuffix
+ Expect(31, t); // "("
+ currentState = 211;
break;
}
- case 208: {
- Expect(155, t); // "Of"
- currentState = 209;
+ case 204: {
+ Expect(162, t); // "Of"
+ currentState = 205;
break;
}
- case 209: {
- stateStack.Push(212);
- goto case 196; // TypeName
+ case 205: {
+ stateStack.Push(208);
+ goto case 192; // TypeName
}
- case 210: {
- Expect(12, t); // ","
- currentState = 211;
+ case 206: {
+ Expect(18, t); // ","
+ currentState = 207;
break;
}
- case 211: {
- stateStack.Push(212);
- goto case 196; // TypeName
+ case 207: {
+ stateStack.Push(208);
+ goto case 192; // TypeName
}
- case 212: {
- if (t.kind == 12) {
- goto case 210;
+ case 208: {
+ if (t.kind == 18) {
+ goto case 206;
} else {
- goto case 217;
+ goto case 213;
}
}
- case 213: {
- Expect(12, t); // ","
- currentState = 214;
+ case 209: {
+ Expect(18, t); // ","
+ currentState = 210;
break;
}
- case 214: {
- if (t.kind == 12) {
- goto case 213;
+ case 210: {
+ if (t.kind == 18) {
+ goto case 209;
} else {
- goto case 217;
+ goto case 213;
}
}
- case 215: {
- if (t.kind == 155) {
- goto case 208;
+ case 211: {
+ if (t.kind == 162) {
+ goto case 204;
} else {
- goto case 216;
+ goto case 212;
}
}
- case 216: {
- if (t.kind == 12 || t.kind == 26) {
- goto case 214;
+ case 212: {
+ if (t.kind == 18 || t.kind == 32) {
+ goto case 210;
} else {
Error(t);
- goto case 217;
+ goto case 213;
}
}
- case 217: {
- Expect(26, t); // ")"
+ case 213: {
+ Expect(32, t); // ")"
currentState = stateStack.Pop();
break;
}
- case 218: { // start of IdentifierOrKeyword
+ case 214: { // start of IdentifierOrKeyword
currentState = stateStack.Pop();
break;
}
- case 219: {
+ case 215: {
Expect(3, t); // LiteralString
currentState = stateStack.Pop();
break;
}
- case 220: {
+ case 216: {
Expect(4, t); // LiteralCharacter
currentState = stateStack.Pop();
break;
}
- case 221: { // start of Literal
+ case 217: { // start of Literal
if (t.kind == 3) {
+ goto case 215;
+ } else {
+ goto case 218;
+ }
+ }
+ case 218: {
+ if (t.kind == 4) {
+ goto case 216;
+ } else {
+ goto case 220;
+ }
+ }
+ case 219: {
+ Expect(5, t); // LiteralInteger
+ currentState = stateStack.Pop();
+ break;
+ }
+ case 220: {
+ if (t.kind == 5) {
goto case 219;
} else {
goto case 222;
}
}
+ case 221: {
+ Expect(6, t); // LiteralDouble
+ currentState = stateStack.Pop();
+ break;
+ }
case 222: {
- if (t.kind == 4) {
- goto case 220;
+ if (t.kind == 6) {
+ goto case 221;
} else {
goto case 224;
}
}
case 223: {
- Expect(5, t); // LiteralInteger
+ Expect(7, t); // LiteralSingle
currentState = stateStack.Pop();
break;
}
case 224: {
- if (t.kind == 5) {
+ if (t.kind == 7) {
goto case 223;
} else {
goto case 226;
}
}
case 225: {
- Expect(6, t); // LiteralDouble
+ Expect(8, t); // LiteralDecimal
currentState = stateStack.Pop();
break;
}
case 226: {
- if (t.kind == 6) {
+ if (t.kind == 8) {
goto case 225;
} else {
goto case 228;
}
}
case 227: {
- Expect(7, t); // LiteralSingle
+ Expect(9, t); // LiteralDate
currentState = stateStack.Pop();
break;
}
case 228: {
- if (t.kind == 7) {
+ if (t.kind == 9) {
goto case 227;
} else {
goto case 230;
}
}
case 229: {
- Expect(8, t); // LiteralDecimal
+ Expect(209, t); // "True"
currentState = stateStack.Pop();
break;
}
case 230: {
- if (t.kind == 8) {
+ if (t.kind == 209) {
goto case 229;
} else {
goto case 232;
}
}
case 231: {
- Expect(9, t); // LiteralDate
+ Expect(115, t); // "False"
currentState = stateStack.Pop();
break;
}
case 232: {
- if (t.kind == 9) {
+ if (t.kind == 115) {
goto case 231;
} else {
goto case 234;
}
}
case 233: {
- Expect(202, t); // "True"
+ Expect(158, t); // "Nothing"
currentState = stateStack.Pop();
break;
}
case 234: {
- if (t.kind == 202) {
+ if (t.kind == 158) {
goto case 233;
} else {
goto case 236;
}
}
case 235: {
- Expect(109, t); // "False"
+ Expect(146, t); // "Me"
currentState = stateStack.Pop();
break;
}
case 236: {
- if (t.kind == 109) {
+ if (t.kind == 146) {
goto case 235;
} else {
goto case 238;
}
}
case 237: {
- Expect(151, t); // "Nothing"
+ Expect(151, t); // "MyBase"
currentState = stateStack.Pop();
break;
}
@@ -1348,691 +1354,691 @@ int currentState = 1;
}
}
case 239: {
- Expect(139, t); // "Me"
+ Expect(152, t); // "MyClass"
currentState = stateStack.Pop();
break;
}
case 240: {
- if (t.kind == 139) {
+ if (t.kind == 152) {
goto case 239;
} else {
- goto case 242;
+ Error(t);
+ currentState = stateStack.Pop();
+ goto switchlbl;
}
}
case 241: {
- Expect(144, t); // "MyBase"
- currentState = stateStack.Pop();
- break;
+ stateStack.Push(245);
+ goto case 283; // Identifier
}
case 242: {
- if (t.kind == 144) {
- goto case 241;
- } else {
- goto case 244;
- }
+ Expect(5, t); // LiteralInteger
+ currentState = 245;
+ break;
}
case 243: {
- Expect(145, t); // "MyClass"
- currentState = stateStack.Pop();
- break;
+ if (set[13, t.kind]) {
+ goto case 241;
+ } else {
+ goto case 244;
+ }
}
case 244: {
- if (t.kind == 145) {
- goto case 243;
+ if (t.kind == 5) {
+ goto case 242;
} else {
Error(t);
- currentState = stateStack.Pop();
- goto switchlbl;
+ goto case 245;
}
}
case 245: {
- stateStack.Push(249);
- goto case 287; // Identifier
+ Expect(17, t); // ":"
+ currentState = stateStack.Pop();
+ break;
}
case 246: {
- Expect(5, t); // LiteralInteger
- currentState = 249;
+ Expect(98, t); // "Dim"
+ currentState = 252;
break;
}
case 247: {
- if (set[13, t.kind]) {
- goto case 245;
- } else {
- goto case 248;
- }
+ Expect(196, t); // "Static"
+ currentState = 252;
+ break;
}
case 248: {
- if (t.kind == 5) {
+ if (t.kind == 98) {
goto case 246;
} else {
- Error(t);
goto case 249;
}
}
case 249: {
- Expect(11, t); // ":"
- currentState = stateStack.Pop();
- break;
+ if (t.kind == 196) {
+ goto case 247;
+ } else {
+ goto case 251;
+ }
}
case 250: {
- Expect(92, t); // "Dim"
- currentState = 256;
+ Expect(81, t); // "Const"
+ currentState = 252;
break;
}
case 251: {
- Expect(189, t); // "Static"
- currentState = 256;
- break;
- }
- case 252: {
- if (t.kind == 92) {
+ if (t.kind == 81) {
goto case 250;
} else {
- goto case 253;
+ Error(t);
+ goto case 252;
}
}
- case 253: {
- if (t.kind == 189) {
- goto case 251;
- } else {
- goto case 255;
- }
+ case 252: {
+ stateStack.Push(254);
+ goto case 283; // Identifier
}
- case 254: {
- Expect(75, t); // "Const"
- currentState = 256;
+ case 253: {
+ Expect(27, t); // "?"
+ currentState = 259;
break;
}
- case 255: {
- if (t.kind == 75) {
- goto case 254;
+ case 254: {
+ if (t.kind == 27) {
+ goto case 253;
} else {
- Error(t);
- goto case 256;
+ goto case 259;
}
}
- case 256: {
- stateStack.Push(258);
- goto case 287; // Identifier
+ case 255: {
+ Expect(31, t); // "("
+ currentState = 257;
+ break;
}
- case 257: {
- Expect(21, t); // "?"
- currentState = 263;
+ case 256: {
+ Expect(18, t); // ","
+ currentState = 257;
break;
}
- case 258: {
- if (t.kind == 21) {
- goto case 257;
+ case 257: {
+ if (t.kind == 18) {
+ goto case 256;
} else {
- goto case 263;
+ goto case 258;
}
}
- case 259: {
- Expect(25, t); // "("
- currentState = 261;
+ case 258: {
+ Expect(32, t); // ")"
+ currentState = 269;
break;
}
+ case 259: {
+ if (t.kind == 31) {
+ goto case 255;
+ } else {
+ goto case 269;
+ }
+ }
case 260: {
- Expect(12, t); // ","
+ Expect(18, t); // ","
currentState = 261;
break;
}
case 261: {
- if (t.kind == 12) {
- goto case 260;
- } else {
- goto case 262;
- }
+ stateStack.Push(263);
+ goto case 283; // Identifier
}
case 262: {
- Expect(26, t); // ")"
- currentState = 273;
+ Expect(27, t); // "?"
+ currentState = 268;
break;
}
case 263: {
- if (t.kind == 25) {
- goto case 259;
+ if (t.kind == 27) {
+ goto case 262;
} else {
- goto case 273;
+ goto case 268;
}
}
case 264: {
- Expect(12, t); // ","
- currentState = 265;
+ Expect(31, t); // "("
+ currentState = 266;
break;
}
case 265: {
- stateStack.Push(267);
- goto case 287; // Identifier
- }
- case 266: {
- Expect(21, t); // "?"
- currentState = 272;
+ Expect(18, t); // ","
+ currentState = 266;
break;
}
- case 267: {
- if (t.kind == 21) {
- goto case 266;
+ case 266: {
+ if (t.kind == 18) {
+ goto case 265;
} else {
- goto case 272;
+ goto case 267;
}
}
- case 268: {
- Expect(25, t); // "("
- currentState = 270;
- break;
- }
- case 269: {
- Expect(12, t); // ","
- currentState = 270;
+ case 267: {
+ Expect(32, t); // ")"
+ currentState = 269;
break;
}
- case 270: {
- if (t.kind == 12) {
+ case 268: {
+ if (t.kind == 31) {
+ goto case 264;
+ } else {
goto case 269;
+ }
+ }
+ case 269: {
+ if (t.kind == 18) {
+ goto case 260;
} else {
- goto case 271;
+ goto case 277;
}
}
+ case 270: {
+ Expect(56, t); // "As"
+ currentState = 272;
+ break;
+ }
case 271: {
- Expect(26, t); // ")"
+ Expect(155, t); // "New"
currentState = 273;
break;
}
case 272: {
- if (t.kind == 25) {
- goto case 268;
+ if (t.kind == 155) {
+ goto case 271;
} else {
goto case 273;
}
}
case 273: {
- if (t.kind == 12) {
- goto case 264;
- } else {
- goto case 281;
- }
+ stateStack.Push(276);
+ goto case 192; // TypeName
}
case 274: {
- Expect(50, t); // "As"
- currentState = 276;
+ Expect(31, t); // "("
+ currentState = 275;
break;
}
case 275: {
- Expect(148, t); // "New"
- currentState = 277;
+ Expect(32, t); // ")"
+ currentState = 280;
break;
}
case 276: {
- if (t.kind == 148) {
- goto case 275;
+ if (t.kind == 31) {
+ goto case 274;
} else {
- goto case 277;
+ goto case 280;
}
}
case 277: {
- stateStack.Push(280);
- goto case 196; // TypeName
+ if (t.kind == 56) {
+ goto case 270;
+ } else {
+ goto case 280;
+ }
}
case 278: {
- Expect(25, t); // "("
+ Expect(16, t); // "="
currentState = 279;
break;
}
case 279: {
- Expect(26, t); // ")"
- currentState = 284;
- break;
+ goto case 132; // Expression
}
case 280: {
- if (t.kind == 25) {
+ if (t.kind == 16) {
goto case 278;
- } else {
- goto case 284;
- }
- }
- case 281: {
- if (t.kind == 50) {
- goto case 274;
- } else {
- goto case 284;
- }
- }
- case 282: {
- Expect(10, t); // "="
- currentState = 283;
- break;
- }
- case 283: {
- goto case 132; // Expression
- }
- case 284: {
- if (t.kind == 10) {
- goto case 282;
} else {
currentState = stateStack.Pop();
goto switchlbl;
}
}
- case 285: { // start of Statement
+ case 281: { // start of Statement
if (set[15, t.kind]) {
- goto case 247;
+ goto case 243;
} else {
- goto case 286;
+ goto case 282;
}
}
- case 286: {
- if (t.kind == 75 || t.kind == 92 || t.kind == 189) {
- goto case 252;
+ case 282: {
+ if (t.kind == 81 || t.kind == 98 || t.kind == 196) {
+ goto case 248;
} else {
Error(t);
currentState = stateStack.Pop();
goto switchlbl;
}
}
- case 287: { // start of Identifier
+ case 283: { // start of Identifier
PushContext(Context.IdentifierExpected);
- goto case 290;
+ goto case 286;
}
- case 288: {
- stateStack.Push(292);
- goto case 295; // IdentifierForFieldDeclaration
+ case 284: {
+ stateStack.Push(288);
+ goto case 291; // IdentifierForFieldDeclaration
}
- case 289: {
- Expect(85, t); // "Custom"
- currentState = 292;
+ case 285: {
+ Expect(91, t); // "Custom"
+ currentState = 288;
break;
}
- case 290: {
+ case 286: {
if (set[16, t.kind]) {
- goto case 288;
+ goto case 284;
} else {
- goto case 291;
+ goto case 287;
}
}
- case 291: {
- if (t.kind == 85) {
- goto case 289;
+ case 287: {
+ if (t.kind == 91) {
+ goto case 285;
} else {
Error(t);
- goto case 292;
+ goto case 288;
}
}
- case 292: {
+ case 288: {
PopContext();
currentState = stateStack.Pop();
goto switchlbl;
}
- case 293: {
+ case 289: {
Expect(2, t); // ident
currentState = stateStack.Pop();
break;
}
- case 294: {
- Expect(45, t); // "Aggregate"
+ case 290: {
+ Expect(51, t); // "Aggregate"
currentState = stateStack.Pop();
break;
}
- case 295: { // start of IdentifierForFieldDeclaration
+ case 291: { // start of IdentifierForFieldDeclaration
if (t.kind == 2) {
+ goto case 289;
+ } else {
+ goto case 292;
+ }
+ }
+ case 292: {
+ if (t.kind == 51) {
+ goto case 290;
+ } else {
+ goto case 294;
+ }
+ }
+ case 293: {
+ Expect(55, t); // "Ansi"
+ currentState = stateStack.Pop();
+ break;
+ }
+ case 294: {
+ if (t.kind == 55) {
goto case 293;
} else {
goto case 296;
}
}
+ case 295: {
+ Expect(57, t); // "Ascending"
+ currentState = stateStack.Pop();
+ break;
+ }
case 296: {
- if (t.kind == 45) {
- goto case 294;
+ if (t.kind == 57) {
+ goto case 295;
} else {
goto case 298;
}
}
case 297: {
- Expect(49, t); // "Ansi"
+ Expect(58, t); // "Assembly"
currentState = stateStack.Pop();
break;
}
case 298: {
- if (t.kind == 49) {
+ if (t.kind == 58) {
goto case 297;
} else {
goto case 300;
}
}
case 299: {
- Expect(51, t); // "Ascending"
+ Expect(59, t); // "Auto"
currentState = stateStack.Pop();
break;
}
case 300: {
- if (t.kind == 51) {
+ if (t.kind == 59) {
goto case 299;
} else {
goto case 302;
}
}
case 301: {
- Expect(52, t); // "Assembly"
+ Expect(60, t); // "Binary"
currentState = stateStack.Pop();
break;
}
case 302: {
- if (t.kind == 52) {
+ if (t.kind == 60) {
goto case 301;
} else {
goto case 304;
}
}
case 303: {
- Expect(53, t); // "Auto"
+ Expect(63, t); // "By"
currentState = stateStack.Pop();
break;
}
case 304: {
- if (t.kind == 53) {
+ if (t.kind == 63) {
goto case 303;
} else {
goto case 306;
}
}
case 305: {
- Expect(54, t); // "Binary"
+ Expect(80, t); // "Compare"
currentState = stateStack.Pop();
break;
}
case 306: {
- if (t.kind == 54) {
+ if (t.kind == 80) {
goto case 305;
} else {
goto case 308;
}
}
case 307: {
- Expect(57, t); // "By"
+ Expect(97, t); // "Descending"
currentState = stateStack.Pop();
break;
}
case 308: {
- if (t.kind == 57) {
+ if (t.kind == 97) {
goto case 307;
} else {
goto case 310;
}
}
case 309: {
- Expect(74, t); // "Compare"
+ Expect(100, t); // "Distinct"
currentState = stateStack.Pop();
break;
}
case 310: {
- if (t.kind == 74) {
+ if (t.kind == 100) {
goto case 309;
} else {
goto case 312;
}
}
case 311: {
- Expect(91, t); // "Descending"
+ Expect(109, t); // "Equals"
currentState = stateStack.Pop();
break;
}
case 312: {
- if (t.kind == 91) {
+ if (t.kind == 109) {
goto case 311;
} else {
goto case 314;
}
}
case 313: {
- Expect(94, t); // "Distinct"
+ Expect(114, t); // "Explicit"
currentState = stateStack.Pop();
break;
}
case 314: {
- if (t.kind == 94) {
+ if (t.kind == 114) {
goto case 313;
} else {
goto case 316;
}
}
case 315: {
- Expect(103, t); // "Equals"
+ Expect(119, t); // "From"
currentState = stateStack.Pop();
break;
}
case 316: {
- if (t.kind == 103) {
+ if (t.kind == 119) {
goto case 315;
} else {
goto case 318;
}
}
case 317: {
- Expect(108, t); // "Explicit"
+ Expect(126, t); // "Group"
currentState = stateStack.Pop();
break;
}
case 318: {
- if (t.kind == 108) {
+ if (t.kind == 126) {
goto case 317;
} else {
goto case 320;
}
}
case 319: {
- Expect(113, t); // "From"
+ Expect(132, t); // "Infer"
currentState = stateStack.Pop();
break;
}
case 320: {
- if (t.kind == 113) {
+ if (t.kind == 132) {
goto case 319;
} else {
goto case 322;
}
}
case 321: {
- Expect(120, t); // "Group"
+ Expect(136, t); // "Into"
currentState = stateStack.Pop();
break;
}
case 322: {
- if (t.kind == 120) {
+ if (t.kind == 136) {
goto case 321;
} else {
goto case 324;
}
}
case 323: {
- Expect(126, t); // "Infer"
+ Expect(139, t); // "Join"
currentState = stateStack.Pop();
break;
}
case 324: {
- if (t.kind == 126) {
+ if (t.kind == 139) {
goto case 323;
} else {
goto case 326;
}
}
case 325: {
- Expect(130, t); // "Into"
+ Expect(163, t); // "Off"
currentState = stateStack.Pop();
break;
}
case 326: {
- if (t.kind == 130) {
+ if (t.kind == 163) {
goto case 325;
} else {
goto case 328;
}
}
case 327: {
- Expect(133, t); // "Join"
+ Expect(169, t); // "Order"
currentState = stateStack.Pop();
break;
}
case 328: {
- if (t.kind == 133) {
+ if (t.kind == 169) {
goto case 327;
} else {
goto case 330;
}
}
case 329: {
- Expect(156, t); // "Off"
+ Expect(176, t); // "Preserve"
currentState = stateStack.Pop();
break;
}
case 330: {
- if (t.kind == 156) {
+ if (t.kind == 176) {
goto case 329;
} else {
goto case 332;
}
}
case 331: {
- Expect(162, t); // "Order"
+ Expect(195, t); // "Skip"
currentState = stateStack.Pop();
break;
}
case 332: {
- if (t.kind == 162) {
+ if (t.kind == 195) {
goto case 331;
} else {
goto case 334;
}
}
case 333: {
- Expect(169, t); // "Preserve"
+ Expect(204, t); // "Take"
currentState = stateStack.Pop();
break;
}
case 334: {
- if (t.kind == 169) {
+ if (t.kind == 204) {
goto case 333;
} else {
goto case 336;
}
}
case 335: {
- Expect(188, t); // "Skip"
+ Expect(205, t); // "Text"
currentState = stateStack.Pop();
break;
}
case 336: {
- if (t.kind == 188) {
+ if (t.kind == 205) {
goto case 335;
} else {
goto case 338;
}
}
case 337: {
- Expect(197, t); // "Take"
+ Expect(215, t); // "Unicode"
currentState = stateStack.Pop();
break;
}
case 338: {
- if (t.kind == 197) {
+ if (t.kind == 215) {
goto case 337;
} else {
goto case 340;
}
}
case 339: {
- Expect(198, t); // "Text"
+ Expect(216, t); // "Until"
currentState = stateStack.Pop();
break;
}
case 340: {
- if (t.kind == 198) {
+ if (t.kind == 216) {
goto case 339;
} else {
goto case 342;
}
}
case 341: {
- Expect(208, t); // "Unicode"
+ Expect(222, t); // "Where"
currentState = stateStack.Pop();
break;
}
case 342: {
- if (t.kind == 208) {
+ if (t.kind == 222) {
goto case 341;
} else {
- goto case 344;
+ Error(t);
+ currentState = stateStack.Pop();
+ goto switchlbl;
}
}
case 343: {
- Expect(209, t); // "Until"
+ Expect(180, t); // "Public"
currentState = stateStack.Pop();
break;
}
case 344: {
- if (t.kind == 209) {
+ Expect(118, t); // "Friend"
+ currentState = stateStack.Pop();
+ break;
+ }
+ case 345: { // start of AccessModifier
+ if (t.kind == 180) {
goto case 343;
} else {
goto case 346;
}
}
- case 345: {
- Expect(215, t); // "Where"
- currentState = stateStack.Pop();
- break;
- }
case 346: {
- if (t.kind == 215) {
- goto case 345;
+ if (t.kind == 118) {
+ goto case 344;
} else {
- Error(t);
- currentState = stateStack.Pop();
- goto switchlbl;
+ goto case 348;
}
}
case 347: {
- Expect(173, t); // "Public"
+ Expect(179, t); // "Protected"
currentState = stateStack.Pop();
break;
}
case 348: {
- Expect(112, t); // "Friend"
- currentState = stateStack.Pop();
- break;
- }
- case 349: { // start of AccessModifier
- if (t.kind == 173) {
+ if (t.kind == 179) {
goto case 347;
} else {
goto case 350;
}
}
+ case 349: {
+ Expect(177, t); // "Private"
+ currentState = stateStack.Pop();
+ break;
+ }
case 350: {
- if (t.kind == 112) {
- goto case 348;
+ if (t.kind == 177) {
+ goto case 349;
} else {
- goto case 352;
+ Error(t);
+ currentState = stateStack.Pop();
+ goto switchlbl;
}
}
case 351: {
- Expect(172, t); // "Protected"
+ goto case 345; // AccessModifier
+ }
+ case 352: {
+ Expect(191, t); // "Shadows"
currentState = stateStack.Pop();
break;
}
- case 352: {
- if (t.kind == 172) {
+ case 353: { // start of TypeModifier
+ if (set[17, t.kind]) {
goto case 351;
} else {
goto case 354;
}
}
- case 353: {
- Expect(170, t); // "Private"
- currentState = stateStack.Pop();
- break;
- }
case 354: {
- if (t.kind == 170) {
- goto case 353;
+ if (t.kind == 191) {
+ goto case 352;
} else {
Error(t);
currentState = stateStack.Pop();
@@ -2040,14 +2046,14 @@ int currentState = 1;
}
}
case 355: {
- goto case 349; // AccessModifier
+ goto case 345; // AccessModifier
}
case 356: {
- Expect(184, t); // "Shadows"
+ Expect(191, t); // "Shadows"
currentState = stateStack.Pop();
break;
}
- case 357: { // start of TypeModifier
+ case 357: { // start of MemberModifier
if (set[17, t.kind]) {
goto case 355;
} else {
@@ -2055,178 +2061,154 @@ int currentState = 1;
}
}
case 358: {
- if (t.kind == 184) {
+ if (t.kind == 191) {
goto case 356;
} else {
- Error(t);
- currentState = stateStack.Pop();
- goto switchlbl;
+ goto case 360;
}
}
case 359: {
- goto case 349; // AccessModifier
- }
- case 360: {
- Expect(184, t); // "Shadows"
+ Expect(192, t); // "Shared"
currentState = stateStack.Pop();
break;
}
- case 361: { // start of MemberModifier
- if (set[17, t.kind]) {
+ case 360: {
+ if (t.kind == 192) {
goto case 359;
} else {
goto case 362;
}
}
+ case 361: {
+ Expect(172, t); // "Overridable"
+ currentState = stateStack.Pop();
+ break;
+ }
case 362: {
- if (t.kind == 184) {
- goto case 360;
+ if (t.kind == 172) {
+ goto case 361;
} else {
goto case 364;
}
}
case 363: {
- Expect(185, t); // "Shared"
+ Expect(160, t); // "NotOverridable"
currentState = stateStack.Pop();
break;
}
case 364: {
- if (t.kind == 185) {
+ if (t.kind == 160) {
goto case 363;
} else {
goto case 366;
}
}
case 365: {
- Expect(165, t); // "Overridable"
+ Expect(173, t); // "Overrides"
currentState = stateStack.Pop();
break;
}
case 366: {
- if (t.kind == 165) {
+ if (t.kind == 173) {
goto case 365;
} else {
goto case 368;
}
}
case 367: {
- Expect(153, t); // "NotOverridable"
+ Expect(171, t); // "Overloads"
currentState = stateStack.Pop();
break;
}
case 368: {
- if (t.kind == 153) {
+ if (t.kind == 171) {
goto case 367;
} else {
goto case 370;
}
}
case 369: {
- Expect(166, t); // "Overrides"
+ Expect(175, t); // "Partial"
currentState = stateStack.Pop();
break;
}
case 370: {
- if (t.kind == 166) {
+ if (t.kind == 175) {
goto case 369;
} else {
goto case 372;
}
}
case 371: {
- Expect(164, t); // "Overloads"
+ Expect(226, t); // "WithEvents"
currentState = stateStack.Pop();
break;
}
case 372: {
- if (t.kind == 164) {
+ if (t.kind == 226) {
goto case 371;
} else {
goto case 374;
}
}
case 373: {
- Expect(168, t); // "Partial"
+ Expect(98, t); // "Dim"
currentState = stateStack.Pop();
break;
}
case 374: {
- if (t.kind == 168) {
+ if (t.kind == 98) {
goto case 373;
} else {
- goto case 376;
+ Error(t);
+ currentState = stateStack.Pop();
+ goto switchlbl;
}
}
case 375: {
- Expect(219, t); // "WithEvents"
+ Expect(65, t); // "ByVal"
currentState = stateStack.Pop();
break;
}
case 376: {
- if (t.kind == 219) {
+ Expect(62, t); // "ByRef"
+ currentState = stateStack.Pop();
+ break;
+ }
+ case 377: { // start of ParameterModifier
+ if (t.kind == 65) {
goto case 375;
} else {
goto case 378;
}
}
- case 377: {
- Expect(92, t); // "Dim"
- currentState = stateStack.Pop();
- break;
- }
case 378: {
- if (t.kind == 92) {
- goto case 377;
+ if (t.kind == 62) {
+ goto case 376;
} else {
- Error(t);
- currentState = stateStack.Pop();
- goto switchlbl;
+ goto case 380;
}
}
case 379: {
- Expect(59, t); // "ByVal"
+ Expect(167, t); // "Optional"
currentState = stateStack.Pop();
break;
}
case 380: {
- Expect(56, t); // "ByRef"
- currentState = stateStack.Pop();
- break;
- }
- case 381: { // start of ParameterModifier
- if (t.kind == 59) {
+ if (t.kind == 167) {
goto case 379;
} else {
goto case 382;
}
}
- case 382: {
- if (t.kind == 56) {
- goto case 380;
- } else {
- goto case 384;
- }
- }
- case 383: {
- Expect(160, t); // "Optional"
+ case 381: {
+ Expect(174, t); // "ParamArray"
currentState = stateStack.Pop();
break;
}
- case 384: {
- if (t.kind == 160) {
- goto case 383;
- } else {
- goto case 386;
- }
- }
- case 385: {
- Expect(167, t); // "ParamArray"
- currentState = stateStack.Pop();
- break;
- }
- case 386: {
- if (t.kind == 167) {
- goto case 385;
+ case 382: {
+ if (t.kind == 174) {
+ goto case 381;
} else {
Error(t);
currentState = stateStack.Pop();
@@ -2238,24 +2220,24 @@ int currentState = 1;
}
static readonly bool[,] set = {
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,x},
- {x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, T,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, T,T,T,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,T,x, T,T,T,x, T,T,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,x,x, T,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,T, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, T,T,T,x, T,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, T,T,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,T,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, T,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,T, T,T,T,T, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x}
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,x},
+ {x,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,T,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,T,T, T,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,T,x,T, T,T,x,T, T,T,x,T, T,x,x,x, x,x,x,x, x,x,x,T, T,x,x,T, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,T,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,T, T,T,x,T, x,T,x,T, T,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,x,x, x,x,T,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,T,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x},
+ {x,x,x,T, T,T,T,T, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x},
+ {x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,T,T,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x}
};
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBNetParserTests.cs b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBNetParserTests.cs
new file mode 100644
index 0000000000..4d5bf6b58d
--- /dev/null
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBNetParserTests.cs
@@ -0,0 +1,37 @@
+//
+//
+//
+//
+// $Revision$
+//
+
+
+using System;
+using NUnit.Framework;
+
+namespace VBParserExperiment
+{
+ [TestFixture]
+ public class VBNetParserTests
+ {
+ [Test]
+ [Ignore]
+ // TODO : check results
+ public void CommentAfterEnd()
+ {
+ RunTest(
+ @"Class Test
+ Sub A()
+ Dim a = a
+ End Sub
+End Class",
+ @""
+ );
+ }
+
+ void RunTest(string code, string result)
+ {
+ throw new NotImplementedException();
+ }
+ }
+}
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBParserExperiment.csproj b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBParserExperiment.csproj
index 4c83ba917a..434a23061c 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBParserExperiment.csproj
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/VBParserExperiment.csproj
@@ -51,6 +51,8 @@
+
+
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/XmlModeLexerTests.cs b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/XmlModeLexerTests.cs
new file mode 100644
index 0000000000..e791c02777
--- /dev/null
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Test/XmlModeLexerTests.cs
@@ -0,0 +1,47 @@
+//
+//
+//
+//
+// $Revision$
+//
+
+
+using System;
+using System.IO;
+using ICSharpCode.NRefactory;
+using ICSharpCode.NRefactory.Parser;
+using ICSharpCode.NRefactory.Parser.VB;
+using NUnit.Framework;
+
+namespace VBParserExperiment
+{
+ [TestFixture]
+ public class XmlModeLexerTests
+ {
+ ILexer GenerateLexer(StringReader sr)
+ {
+ return ParserFactory.CreateLexer(SupportedLanguage.VBNet, sr);
+ }
+
+ string TestStatement(string stmt)
+ {
+ return "Class Test\n" +
+ "Sub A()\n" +
+ stmt + "\n" +
+ "End Sub\n" +
+ "End Class";
+ }
+
+ [Test]
+ public void SimpleTag()
+ {
+ ILexer lexer = GenerateLexer(new StringReader(TestStatement("Dim x = ")));
+
+ Assert.AreEqual(Tokens.Class, lexer.NextToken().Kind);
+ Assert.AreEqual(Tokens.Identifier, lexer.NextToken().Kind);
+ Assert.AreEqual(Tokens.EOL, lexer.NextToken().Kind);
+ Assert.AreEqual(Tokens.Sub, lexer.NextToken().Kind);
+ Assert.AreEqual(Tokens.Identifier, lexer.NextToken().Kind);
+ }
+ }
+}
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Parser.cs b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Parser.cs
index 24f50dea7d..57488c40fd 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Parser.cs
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Parser.cs
@@ -1,3 +1,5 @@
+
+#line 1 "VBNET.ATG"
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
@@ -5,46 +7,41 @@ using System.Text;
using ICSharpCode.NRefactory.Ast;
using ICSharpCode.NRefactory.Parser.VB;
using ASTAttribute = ICSharpCode.NRefactory.Ast.Attribute;
-
-
-
+/*
+ Parser.frame file for NRefactory.
+ */
using System;
+using System.Reflection;
namespace ICSharpCode.NRefactory.Parser.VB {
+
partial class Parser : AbstractParser
{
- public const int _EOF = 0;
- public const int _EOL = 1;
- public const int _ident = 2;
- public const int _LiteralString = 3;
- public const int _LiteralCharacter = 4;
- public const int _LiteralInteger = 5;
- public const int _LiteralDouble = 6;
- public const int _LiteralSingle = 7;
- public const int _LiteralDecimal = 8;
- public const int _LiteralDate = 9;
- public const int maxT = 222; // usings = new List();
+#line 300 "VBNET.ATG"
+ List usings = new List();
+
Expect(124);
+
+#line 304 "VBNET.ATG"
Location startPos = t.Location;
Using u;
+
+ ImportClause(
+#line 307 "VBNET.ATG"
+out u);
- ImportClause(out u);
- if (u != null) { usings.Add(u); }
+#line 307 "VBNET.ATG"
+ if (u != null) { usings.Add(u); }
while (la.kind == 12) {
- Get();
- ImportClause(out u);
- if (u != null) { usings.Add(u); }
+ lexer.NextToken();
+ ImportClause(
+#line 309 "VBNET.ATG"
+out u);
+
+#line 309 "VBNET.ATG"
+ if (u != null) { usings.Add(u); }
}
EndOfStmt();
+
+#line 313 "VBNET.ATG"
UsingDeclaration usingDeclaration = new UsingDeclaration(usings);
usingDeclaration.StartLocation = startPos;
usingDeclaration.EndLocation = t.Location;
compilationUnit.AddChild(usingDeclaration);
-
+
}
void GlobalAttributeSection() {
Expect(28);
- Location startPos = t.Location;
+
+#line 2575 "VBNET.ATG"
+ Location startPos = t.Location;
if (la.kind == 52) {
- Get();
- } else if (la.kind == 141) {
- Get();
- } else SynErr(226);
+ lexer.NextToken();
+ } else if (la.kind == 142) {
+ lexer.NextToken();
+ } else SynErr(227);
+
+#line 2577 "VBNET.ATG"
string attributeTarget = t.val != null ? t.val.ToLower(System.Globalization.CultureInfo.InvariantCulture) : null;
List attributes = new List();
ASTAttribute attribute;
-
+
Expect(11);
- Attribute(out attribute);
- attributes.Add(attribute);
- while (NotFinalComma()) {
+ Attribute(
+#line 2581 "VBNET.ATG"
+out attribute);
+
+#line 2581 "VBNET.ATG"
+ attributes.Add(attribute);
+ while (
+#line 2582 "VBNET.ATG"
+NotFinalComma()) {
if (la.kind == 12) {
- Get();
+ lexer.NextToken();
if (la.kind == 52) {
- Get();
- } else if (la.kind == 141) {
- Get();
- } else SynErr(227);
+ lexer.NextToken();
+ } else if (la.kind == 142) {
+ lexer.NextToken();
+ } else SynErr(228);
Expect(11);
}
- Attribute(out attribute);
- attributes.Add(attribute);
+ Attribute(
+#line 2582 "VBNET.ATG"
+out attribute);
+
+#line 2582 "VBNET.ATG"
+ attributes.Add(attribute);
}
if (la.kind == 12) {
- Get();
+ lexer.NextToken();
}
Expect(27);
EndOfStmt();
+
+#line 2587 "VBNET.ATG"
AttributeSection section = new AttributeSection {
AttributeTarget = attributeTarget,
Attributes = attributes,
@@ -182,63 +233,97 @@ partial class Parser : AbstractParser
EndLocation = t.EndLocation
};
compilationUnit.AddChild(section);
-
+
}
void NamespaceMemberDecl() {
+
+#line 346 "VBNET.ATG"
ModifierList m = new ModifierList();
AttributeSection section;
List attributes = new List();
string qualident;
+
+ if (la.kind == 147) {
+ lexer.NextToken();
- if (la.kind == 146) {
- Get();
+#line 353 "VBNET.ATG"
Location startPos = t.Location;
+
+ Qualident(
+#line 355 "VBNET.ATG"
+out qualident);
- Qualident(out qualident);
+#line 357 "VBNET.ATG"
INode node = new NamespaceDeclaration(qualident);
node.StartLocation = startPos;
compilationUnit.AddChild(node);
compilationUnit.BlockStart(node);
-
+
EndOfStmt();
NamespaceBody();
+
+#line 365 "VBNET.ATG"
node.EndLocation = t.Location;
compilationUnit.BlockEnd();
-
+
} else if (StartOf(2)) {
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 369 "VBNET.ATG"
+out section);
+
+#line 369 "VBNET.ATG"
+ attributes.Add(section);
}
while (StartOf(3)) {
- TypeModifier(m);
+ TypeModifier(
+#line 370 "VBNET.ATG"
+m);
}
- NonModuleDeclaration(m, attributes);
- } else SynErr(228);
+ NonModuleDeclaration(
+#line 370 "VBNET.ATG"
+m, attributes);
+ } else SynErr(229);
}
- void OptionValue(ref bool val) {
- if (la.kind == 157) {
- Get();
- val = true;
- } else if (la.kind == 156) {
- Get();
- val = false;
- } else SynErr(229);
+ void OptionValue(
+#line 285 "VBNET.ATG"
+ref bool val) {
+ if (la.kind == 158) {
+ lexer.NextToken();
+
+#line 287 "VBNET.ATG"
+ val = true;
+ } else if (la.kind == 157) {
+ lexer.NextToken();
+
+#line 289 "VBNET.ATG"
+ val = false;
+ } else SynErr(230);
}
- void ImportClause(out Using u) {
+ void ImportClause(
+#line 320 "VBNET.ATG"
+out Using u) {
+
+#line 322 "VBNET.ATG"
string qualident = null;
TypeReference aliasedType = null;
u = null;
-
+
if (StartOf(4)) {
- Qualident(out qualident);
+ Qualident(
+#line 327 "VBNET.ATG"
+out qualident);
if (la.kind == 10) {
- Get();
- TypeName(out aliasedType);
+ lexer.NextToken();
+ TypeName(
+#line 328 "VBNET.ATG"
+out aliasedType);
}
+
+#line 330 "VBNET.ATG"
if (qualident != null && qualident.Length > 0) {
if (aliasedType != null) {
u = new Using(qualident, aliasedType);
@@ -246,49 +331,86 @@ partial class Parser : AbstractParser
u = new Using(qualident);
}
}
-
+
} else if (la.kind == 28) {
- string prefix = null;
- Get();
+
+#line 338 "VBNET.ATG"
+ string prefix = null;
+ lexer.NextToken();
Identifier();
- prefix = t.val;
+
+#line 339 "VBNET.ATG"
+ prefix = t.val;
+ if (la.kind == 11) {
+ lexer.NextToken();
+ Identifier();
+
+#line 339 "VBNET.ATG"
+ prefix += ":" + t.val;
+ }
Expect(10);
Expect(3);
- u = new Using(t.literalValue as string, prefix);
+
+#line 339 "VBNET.ATG"
+ u = new Using(t.literalValue as string, prefix);
Expect(27);
- } else SynErr(230);
+ } else SynErr(231);
}
- void Qualident(out string qualident) {
+ void Qualident(
+#line 3333 "VBNET.ATG"
+out string qualident) {
+
+#line 3335 "VBNET.ATG"
string name;
qualidentBuilder.Length = 0;
-
+
Identifier();
- qualidentBuilder.Append(t.val);
- while (DotAndIdentOrKw()) {
+
+#line 3339 "VBNET.ATG"
+ qualidentBuilder.Append(t.val);
+ while (
+#line 3340 "VBNET.ATG"
+DotAndIdentOrKw()) {
Expect(16);
- IdentifierOrKeyword(out name);
- qualidentBuilder.Append('.'); qualidentBuilder.Append(name);
+ IdentifierOrKeyword(
+#line 3340 "VBNET.ATG"
+out name);
+
+#line 3340 "VBNET.ATG"
+ qualidentBuilder.Append('.'); qualidentBuilder.Append(name);
}
- qualident = qualidentBuilder.ToString();
+
+#line 3342 "VBNET.ATG"
+ qualident = qualidentBuilder.ToString();
}
- void TypeName(out TypeReference typeref) {
- ArrayList rank = null;
- NonArrayTypeName(out typeref, false);
- ArrayTypeModifiers(out rank);
+ void TypeName(
+#line 2448 "VBNET.ATG"
+out TypeReference typeref) {
+
+#line 2449 "VBNET.ATG"
+ ArrayList rank = null;
+ NonArrayTypeName(
+#line 2451 "VBNET.ATG"
+out typeref, false);
+ ArrayTypeModifiers(
+#line 2455 "VBNET.ATG"
+out rank);
+
+#line 2456 "VBNET.ATG"
if (rank != null && typeref != null) {
typeref.RankSpecifier = (int[])rank.ToArray(typeof(int));
}
-
+
}
void Identifier() {
if (StartOf(5)) {
IdentifierForFieldDeclaration();
} else if (la.kind == 85) {
- Get();
- } else SynErr(231);
+ lexer.NextToken();
+ } else SynErr(232);
}
void NamespaceBody() {
@@ -302,26 +424,40 @@ partial class Parser : AbstractParser
}
}
Expect(100);
- Expect(146);
+ Expect(147);
EndOfStmt();
}
- void AttributeSection(out AttributeSection section) {
+ void AttributeSection(
+#line 2650 "VBNET.ATG"
+out AttributeSection section) {
+
+#line 2652 "VBNET.ATG"
string attributeTarget = "";List attributes = new List();
ASTAttribute attribute;
-
-
+
+
Expect(28);
- Location startPos = t.Location;
- if (IsLocalAttrTarget()) {
+
+#line 2656 "VBNET.ATG"
+ Location startPos = t.Location;
+ if (
+#line 2657 "VBNET.ATG"
+IsLocalAttrTarget()) {
if (la.kind == 106) {
- Get();
+ lexer.NextToken();
+
+#line 2658 "VBNET.ATG"
attributeTarget = "event";
- } else if (la.kind == 180) {
- Get();
+ } else if (la.kind == 181) {
+ lexer.NextToken();
+
+#line 2659 "VBNET.ATG"
attributeTarget = "return";
- } else if (StartOf(4)) {
+ } else {
Identifier();
+
+#line 2662 "VBNET.ATG"
string val = t.val.ToLower(System.Globalization.CultureInfo.InvariantCulture);
if (val != "field" || val != "method" ||
val != "module" || val != "param" ||
@@ -329,498 +465,804 @@ partial class Parser : AbstractParser
Error("attribute target specifier (event, return, field," +
"method, module, param, property, or type) expected");
attributeTarget = t.val;
-
- } else SynErr(232);
+
+ }
Expect(11);
}
- Attribute(out attribute);
- attributes.Add(attribute);
- while (NotFinalComma()) {
+ Attribute(
+#line 2672 "VBNET.ATG"
+out attribute);
+
+#line 2672 "VBNET.ATG"
+ attributes.Add(attribute);
+ while (
+#line 2673 "VBNET.ATG"
+NotFinalComma()) {
Expect(12);
- Attribute(out attribute);
- attributes.Add(attribute);
+ Attribute(
+#line 2673 "VBNET.ATG"
+out attribute);
+
+#line 2673 "VBNET.ATG"
+ attributes.Add(attribute);
}
if (la.kind == 12) {
- Get();
+ lexer.NextToken();
}
Expect(27);
+
+#line 2677 "VBNET.ATG"
section = new AttributeSection {
AttributeTarget = attributeTarget,
Attributes = attributes,
StartLocation = startPos,
EndLocation = t.EndLocation
};
-
+
}
- void TypeModifier(ModifierList m) {
+ void TypeModifier(
+#line 3416 "VBNET.ATG"
+ModifierList m) {
switch (la.kind) {
- case 173: {
- Get();
- m.Add(Modifiers.Public, t.Location);
+ case 174: {
+ lexer.NextToken();
+
+#line 3417 "VBNET.ATG"
+ m.Add(Modifiers.Public, t.Location);
break;
}
- case 172: {
- Get();
- m.Add(Modifiers.Protected, t.Location);
+ case 173: {
+ lexer.NextToken();
+
+#line 3418 "VBNET.ATG"
+ m.Add(Modifiers.Protected, t.Location);
break;
}
case 112: {
- Get();
- m.Add(Modifiers.Internal, t.Location);
+ lexer.NextToken();
+
+#line 3419 "VBNET.ATG"
+ m.Add(Modifiers.Internal, t.Location);
break;
}
- case 170: {
- Get();
- m.Add(Modifiers.Private, t.Location);
+ case 171: {
+ lexer.NextToken();
+
+#line 3420 "VBNET.ATG"
+ m.Add(Modifiers.Private, t.Location);
break;
}
- case 185: {
- Get();
- m.Add(Modifiers.Static, t.Location);
+ case 186: {
+ lexer.NextToken();
+
+#line 3421 "VBNET.ATG"
+ m.Add(Modifiers.Static, t.Location);
break;
}
- case 184: {
- Get();
- m.Add(Modifiers.New, t.Location);
+ case 185: {
+ lexer.NextToken();
+
+#line 3422 "VBNET.ATG"
+ m.Add(Modifiers.New, t.Location);
break;
}
- case 142: {
- Get();
- m.Add(Modifiers.Abstract, t.Location);
+ case 143: {
+ lexer.NextToken();
+
+#line 3423 "VBNET.ATG"
+ m.Add(Modifiers.Abstract, t.Location);
break;
}
- case 152: {
- Get();
- m.Add(Modifiers.Sealed, t.Location);
+ case 153: {
+ lexer.NextToken();
+
+#line 3424 "VBNET.ATG"
+ m.Add(Modifiers.Sealed, t.Location);
break;
}
- case 168: {
- Get();
- m.Add(Modifiers.Partial, t.Location);
+ case 169: {
+ lexer.NextToken();
+
+#line 3425 "VBNET.ATG"
+ m.Add(Modifiers.Partial, t.Location);
break;
}
default: SynErr(233); break;
}
}
- void NonModuleDeclaration(ModifierList m, List attributes) {
+ void NonModuleDeclaration(
+#line 430 "VBNET.ATG"
+ModifierList m, List attributes) {
+
+#line 432 "VBNET.ATG"
TypeReference typeRef = null;
List baseInterfaces = null;
-
+
switch (la.kind) {
case 71: {
- m.Check(Modifiers.Classes);
- Get();
+
+#line 435 "VBNET.ATG"
+ m.Check(Modifiers.Classes);
+ lexer.NextToken();
+
+#line 438 "VBNET.ATG"
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
newType.StartLocation = t.Location;
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
-
+
newType.Type = ClassType.Class;
-
+
Identifier();
- newType.Name = t.val;
- TypeParameterList(newType.Templates);
+
+#line 445 "VBNET.ATG"
+ newType.Name = t.val;
+ TypeParameterList(
+#line 446 "VBNET.ATG"
+newType.Templates);
EndOfStmt();
- newType.BodyStartLocation = t.Location;
+
+#line 448 "VBNET.ATG"
+ newType.BodyStartLocation = t.Location;
if (la.kind == 127) {
- ClassBaseType(out typeRef);
- SafeAdd(newType, newType.BaseTypes, typeRef);
+ ClassBaseType(
+#line 449 "VBNET.ATG"
+out typeRef);
+
+#line 449 "VBNET.ATG"
+ SafeAdd(newType, newType.BaseTypes, typeRef);
}
while (la.kind == 123) {
- TypeImplementsClause(out baseInterfaces);
- newType.BaseTypes.AddRange(baseInterfaces);
+ TypeImplementsClause(
+#line 450 "VBNET.ATG"
+out baseInterfaces);
+
+#line 450 "VBNET.ATG"
+ newType.BaseTypes.AddRange(baseInterfaces);
}
- ClassBody(newType);
+ ClassBody(
+#line 451 "VBNET.ATG"
+newType);
Expect(100);
Expect(71);
- newType.EndLocation = t.EndLocation;
+
+#line 452 "VBNET.ATG"
+ newType.EndLocation = t.EndLocation;
EndOfStmt();
- compilationUnit.BlockEnd();
+#line 455 "VBNET.ATG"
+ compilationUnit.BlockEnd();
+
break;
}
- case 141: {
- Get();
+ case 142: {
+ lexer.NextToken();
+
+#line 459 "VBNET.ATG"
m.Check(Modifiers.VBModules);
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
newType.Type = ClassType.Module;
-
+
Identifier();
- newType.Name = t.val;
+
+#line 466 "VBNET.ATG"
+ newType.Name = t.val;
EndOfStmt();
- newType.BodyStartLocation = t.Location;
- ModuleBody(newType);
- compilationUnit.BlockEnd();
+#line 468 "VBNET.ATG"
+ newType.BodyStartLocation = t.Location;
+ ModuleBody(
+#line 469 "VBNET.ATG"
+newType);
+
+#line 471 "VBNET.ATG"
+ compilationUnit.BlockEnd();
+
break;
}
- case 194: {
- Get();
+ case 195: {
+ lexer.NextToken();
+
+#line 475 "VBNET.ATG"
m.Check(Modifiers.VBStructures);
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
newType.Type = ClassType.Struct;
-
+
Identifier();
- newType.Name = t.val;
- TypeParameterList(newType.Templates);
+
+#line 482 "VBNET.ATG"
+ newType.Name = t.val;
+ TypeParameterList(
+#line 483 "VBNET.ATG"
+newType.Templates);
EndOfStmt();
- newType.BodyStartLocation = t.Location;
+
+#line 485 "VBNET.ATG"
+ newType.BodyStartLocation = t.Location;
while (la.kind == 123) {
- TypeImplementsClause(out baseInterfaces);
+ TypeImplementsClause(
+#line 486 "VBNET.ATG"
+out baseInterfaces);
+
+#line 486 "VBNET.ATG"
newType.BaseTypes.AddRange(baseInterfaces);
}
- StructureBody(newType);
- compilationUnit.BlockEnd();
+ StructureBody(
+#line 487 "VBNET.ATG"
+newType);
+#line 489 "VBNET.ATG"
+ compilationUnit.BlockEnd();
+
break;
}
case 102: {
- Get();
+ lexer.NextToken();
+
+#line 494 "VBNET.ATG"
m.Check(Modifiers.VBEnums);
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
-
+
newType.Type = ClassType.Enum;
-
+
Identifier();
- newType.Name = t.val;
+
+#line 502 "VBNET.ATG"
+ newType.Name = t.val;
if (la.kind == 50) {
- Get();
- NonArrayTypeName(out typeRef, false);
- SafeAdd(newType, newType.BaseTypes, typeRef);
+ lexer.NextToken();
+ NonArrayTypeName(
+#line 503 "VBNET.ATG"
+out typeRef, false);
+
+#line 503 "VBNET.ATG"
+ SafeAdd(newType, newType.BaseTypes, typeRef);
}
EndOfStmt();
- newType.BodyStartLocation = t.Location;
- EnumBody(newType);
- compilationUnit.BlockEnd();
+#line 505 "VBNET.ATG"
+ newType.BodyStartLocation = t.Location;
+ EnumBody(
+#line 506 "VBNET.ATG"
+newType);
+
+#line 508 "VBNET.ATG"
+ compilationUnit.BlockEnd();
+
break;
}
case 129: {
- Get();
+ lexer.NextToken();
+
+#line 513 "VBNET.ATG"
m.Check(Modifiers.VBInterfacs);
TypeDeclaration newType = new TypeDeclaration(m.Modifier, attributes);
newType.StartLocation = m.GetDeclarationLocation(t.Location);
compilationUnit.AddChild(newType);
compilationUnit.BlockStart(newType);
newType.Type = ClassType.Interface;
-
+
Identifier();
- newType.Name = t.val;
- TypeParameterList(newType.Templates);
+
+#line 520 "VBNET.ATG"
+ newType.Name = t.val;
+ TypeParameterList(
+#line 521 "VBNET.ATG"
+newType.Templates);
EndOfStmt();
- newType.BodyStartLocation = t.Location;
+
+#line 523 "VBNET.ATG"
+ newType.BodyStartLocation = t.Location;
while (la.kind == 127) {
- InterfaceBase(out baseInterfaces);
- newType.BaseTypes.AddRange(baseInterfaces);
+ InterfaceBase(
+#line 524 "VBNET.ATG"
+out baseInterfaces);
+
+#line 524 "VBNET.ATG"
+ newType.BaseTypes.AddRange(baseInterfaces);
}
- InterfaceBody(newType);
- compilationUnit.BlockEnd();
+ InterfaceBody(
+#line 525 "VBNET.ATG"
+newType);
+#line 527 "VBNET.ATG"
+ compilationUnit.BlockEnd();
+
break;
}
case 90: {
- Get();
+ lexer.NextToken();
+
+#line 532 "VBNET.ATG"
m.Check(Modifiers.VBDelegates);
DelegateDeclaration delegateDeclr = new DelegateDeclaration(m.Modifier, attributes);
delegateDeclr.ReturnType = new TypeReference("System.Void", true);
delegateDeclr.StartLocation = m.GetDeclarationLocation(t.Location);
List p = new List();
-
- if (la.kind == 195) {
- Get();
+
+ if (la.kind == 196) {
+ lexer.NextToken();
Identifier();
- delegateDeclr.Name = t.val;
- TypeParameterList(delegateDeclr.Templates);
+
+#line 539 "VBNET.ATG"
+ delegateDeclr.Name = t.val;
+ TypeParameterList(
+#line 540 "VBNET.ATG"
+delegateDeclr.Templates);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 541 "VBNET.ATG"
+p);
}
Expect(26);
- delegateDeclr.Parameters = p;
+
+#line 541 "VBNET.ATG"
+ delegateDeclr.Parameters = p;
}
} else if (la.kind == 114) {
- Get();
+ lexer.NextToken();
Identifier();
- delegateDeclr.Name = t.val;
- TypeParameterList(delegateDeclr.Templates);
+
+#line 543 "VBNET.ATG"
+ delegateDeclr.Name = t.val;
+ TypeParameterList(
+#line 544 "VBNET.ATG"
+delegateDeclr.Templates);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 545 "VBNET.ATG"
+p);
}
Expect(26);
- delegateDeclr.Parameters = p;
+
+#line 545 "VBNET.ATG"
+ delegateDeclr.Parameters = p;
}
if (la.kind == 50) {
- Get();
- TypeReference type;
- TypeName(out type);
- delegateDeclr.ReturnType = type;
+ lexer.NextToken();
+
+#line 546 "VBNET.ATG"
+ TypeReference type;
+ TypeName(
+#line 546 "VBNET.ATG"
+out type);
+
+#line 546 "VBNET.ATG"
+ delegateDeclr.ReturnType = type;
}
} else SynErr(234);
- delegateDeclr.EndLocation = t.EndLocation;
+
+#line 548 "VBNET.ATG"
+ delegateDeclr.EndLocation = t.EndLocation;
EndOfStmt();
- compilationUnit.AddChild(delegateDeclr);
+#line 551 "VBNET.ATG"
+ compilationUnit.AddChild(delegateDeclr);
+
break;
}
default: SynErr(235); break;
}
}
- void TypeParameterList(List templates) {
- TemplateDefinition template;
+ void TypeParameterList(
+#line 374 "VBNET.ATG"
+List templates) {
- if (la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
- Expect(25);
- Expect(155);
- TypeParameter(out template);
+#line 376 "VBNET.ATG"
+ TemplateDefinition template;
+
+ if (
+#line 380 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
+ lexer.NextToken();
+ Expect(156);
+ TypeParameter(
+#line 381 "VBNET.ATG"
+out template);
+
+#line 383 "VBNET.ATG"
if (template != null) templates.Add(template);
-
+
while (la.kind == 12) {
- Get();
- TypeParameter(out template);
- if (template != null) templates.Add(template);
+ lexer.NextToken();
+ TypeParameter(
+#line 386 "VBNET.ATG"
+out template);
+#line 388 "VBNET.ATG"
+ if (template != null) templates.Add(template);
+
}
Expect(26);
}
}
- void TypeParameter(out TemplateDefinition template) {
+ void TypeParameter(
+#line 396 "VBNET.ATG"
+out TemplateDefinition template) {
Identifier();
- template = new TemplateDefinition(t.val, null);
+
+#line 398 "VBNET.ATG"
+ template = new TemplateDefinition(t.val, null);
if (la.kind == 50) {
- TypeParameterConstraints(template);
+ TypeParameterConstraints(
+#line 399 "VBNET.ATG"
+template);
}
}
- void TypeParameterConstraints(TemplateDefinition template) {
- TypeReference constraint;
+ void TypeParameterConstraints(
+#line 403 "VBNET.ATG"
+TemplateDefinition template) {
+#line 405 "VBNET.ATG"
+ TypeReference constraint;
+
Expect(50);
if (la.kind == 23) {
- Get();
- TypeParameterConstraint(out constraint);
- if (constraint != null) { template.Bases.Add(constraint); }
+ lexer.NextToken();
+ TypeParameterConstraint(
+#line 411 "VBNET.ATG"
+out constraint);
+
+#line 411 "VBNET.ATG"
+ if (constraint != null) { template.Bases.Add(constraint); }
while (la.kind == 12) {
- Get();
- TypeParameterConstraint(out constraint);
- if (constraint != null) { template.Bases.Add(constraint); }
+ lexer.NextToken();
+ TypeParameterConstraint(
+#line 414 "VBNET.ATG"
+out constraint);
+
+#line 414 "VBNET.ATG"
+ if (constraint != null) { template.Bases.Add(constraint); }
}
Expect(24);
} else if (StartOf(7)) {
- TypeParameterConstraint(out constraint);
- if (constraint != null) { template.Bases.Add(constraint); }
+ TypeParameterConstraint(
+#line 417 "VBNET.ATG"
+out constraint);
+
+#line 417 "VBNET.ATG"
+ if (constraint != null) { template.Bases.Add(constraint); }
} else SynErr(236);
}
- void TypeParameterConstraint(out TypeReference constraint) {
- constraint = null;
+ void TypeParameterConstraint(
+#line 421 "VBNET.ATG"
+out TypeReference constraint) {
+
+#line 422 "VBNET.ATG"
+ constraint = null;
if (la.kind == 71) {
- Get();
- constraint = TypeReference.ClassConstraint;
- } else if (la.kind == 194) {
- Get();
- constraint = TypeReference.StructConstraint;
- } else if (la.kind == 148) {
- Get();
- constraint = TypeReference.NewConstraint;
+ lexer.NextToken();
+
+#line 423 "VBNET.ATG"
+ constraint = TypeReference.ClassConstraint;
+ } else if (la.kind == 195) {
+ lexer.NextToken();
+
+#line 424 "VBNET.ATG"
+ constraint = TypeReference.StructConstraint;
+ } else if (la.kind == 149) {
+ lexer.NextToken();
+
+#line 425 "VBNET.ATG"
+ constraint = TypeReference.NewConstraint;
} else if (StartOf(8)) {
- TypeName(out constraint);
+ TypeName(
+#line 426 "VBNET.ATG"
+out constraint);
} else SynErr(237);
}
- void ClassBaseType(out TypeReference typeRef) {
- typeRef = null;
+ void ClassBaseType(
+#line 771 "VBNET.ATG"
+out TypeReference typeRef) {
+#line 773 "VBNET.ATG"
+ typeRef = null;
+
Expect(127);
- TypeName(out typeRef);
+ TypeName(
+#line 776 "VBNET.ATG"
+out typeRef);
EndOfStmt();
}
- void TypeImplementsClause(out List baseInterfaces) {
+ void TypeImplementsClause(
+#line 1588 "VBNET.ATG"
+out List baseInterfaces) {
+
+#line 1590 "VBNET.ATG"
baseInterfaces = new List();
TypeReference type = null;
-
+
Expect(123);
- TypeName(out type);
- if (type != null) baseInterfaces.Add(type);
+ TypeName(
+#line 1593 "VBNET.ATG"
+out type);
+#line 1595 "VBNET.ATG"
+ if (type != null) baseInterfaces.Add(type);
+
while (la.kind == 12) {
- Get();
- TypeName(out type);
- if (type != null) baseInterfaces.Add(type);
+ lexer.NextToken();
+ TypeName(
+#line 1598 "VBNET.ATG"
+out type);
+
+#line 1599 "VBNET.ATG"
+ if (type != null) baseInterfaces.Add(type);
}
EndOfStmt();
}
- void ClassBody(TypeDeclaration newType) {
- AttributeSection section;
+ void ClassBody(
+#line 565 "VBNET.ATG"
+TypeDeclaration newType) {
+
+#line 566 "VBNET.ATG"
+ AttributeSection section;
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
while (StartOf(9)) {
+
+#line 569 "VBNET.ATG"
List attributes = new List();
ModifierList m = new ModifierList();
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 572 "VBNET.ATG"
+out section);
+
+#line 572 "VBNET.ATG"
+ attributes.Add(section);
}
while (StartOf(10)) {
- MemberModifier(m);
+ MemberModifier(
+#line 573 "VBNET.ATG"
+m);
}
- ClassMemberDecl(m, attributes);
+ ClassMemberDecl(
+#line 574 "VBNET.ATG"
+m, attributes);
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
}
}
- void ModuleBody(TypeDeclaration newType) {
- AttributeSection section;
+ void ModuleBody(
+#line 596 "VBNET.ATG"
+TypeDeclaration newType) {
+
+#line 597 "VBNET.ATG"
+ AttributeSection section;
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
while (StartOf(9)) {
+
+#line 600 "VBNET.ATG"
List attributes = new List();
ModifierList m = new ModifierList();
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 603 "VBNET.ATG"
+out section);
+
+#line 603 "VBNET.ATG"
+ attributes.Add(section);
}
while (StartOf(10)) {
- MemberModifier(m);
+ MemberModifier(
+#line 604 "VBNET.ATG"
+m);
}
- ClassMemberDecl(m, attributes);
+ ClassMemberDecl(
+#line 605 "VBNET.ATG"
+m, attributes);
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
}
Expect(100);
- Expect(141);
- newType.EndLocation = t.EndLocation;
+ Expect(142);
+
+#line 608 "VBNET.ATG"
+ newType.EndLocation = t.EndLocation;
EndOfStmt();
}
- void StructureBody(TypeDeclaration newType) {
- AttributeSection section;
+ void StructureBody(
+#line 579 "VBNET.ATG"
+TypeDeclaration newType) {
+
+#line 580 "VBNET.ATG"
+ AttributeSection section;
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
while (StartOf(9)) {
+
+#line 583 "VBNET.ATG"
List attributes = new List();
ModifierList m = new ModifierList();
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 586 "VBNET.ATG"
+out section);
+
+#line 586 "VBNET.ATG"
+ attributes.Add(section);
}
while (StartOf(10)) {
- MemberModifier(m);
+ MemberModifier(
+#line 587 "VBNET.ATG"
+m);
}
- StructureMemberDecl(m, attributes);
+ StructureMemberDecl(
+#line 588 "VBNET.ATG"
+m, attributes);
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
}
Expect(100);
- Expect(194);
- newType.EndLocation = t.EndLocation;
+ Expect(195);
+
+#line 591 "VBNET.ATG"
+ newType.EndLocation = t.EndLocation;
EndOfStmt();
}
- void NonArrayTypeName(out TypeReference typeref, bool canBeUnbound) {
+ void NonArrayTypeName(
+#line 2474 "VBNET.ATG"
+out TypeReference typeref, bool canBeUnbound) {
+
+#line 2476 "VBNET.ATG"
string name;
typeref = null;
bool isGlobal = false;
-
+
if (StartOf(11)) {
if (la.kind == 117) {
- Get();
+ lexer.NextToken();
Expect(16);
- isGlobal = true;
+
+#line 2481 "VBNET.ATG"
+ isGlobal = true;
}
- QualIdentAndTypeArguments(out typeref, canBeUnbound);
- typeref.IsGlobal = isGlobal;
+ QualIdentAndTypeArguments(
+#line 2482 "VBNET.ATG"
+out typeref, canBeUnbound);
+
+#line 2483 "VBNET.ATG"
+ typeref.IsGlobal = isGlobal;
while (la.kind == 16) {
- Get();
- TypeReference nestedTypeRef;
- QualIdentAndTypeArguments(out nestedTypeRef, canBeUnbound);
- typeref = new InnerClassTypeReference(typeref, nestedTypeRef.Type, nestedTypeRef.GenericTypes);
- }
- } else if (la.kind == 154) {
- Get();
- typeref = new TypeReference("System.Object", true);
+ lexer.NextToken();
+
+#line 2484 "VBNET.ATG"
+ TypeReference nestedTypeRef;
+ QualIdentAndTypeArguments(
+#line 2485 "VBNET.ATG"
+out nestedTypeRef, canBeUnbound);
+
+#line 2486 "VBNET.ATG"
+ typeref = new InnerClassTypeReference(typeref, nestedTypeRef.Type, nestedTypeRef.GenericTypes);
+ }
+ } else if (la.kind == 155) {
+ lexer.NextToken();
+
+#line 2489 "VBNET.ATG"
+ typeref = new TypeReference("System.Object", true);
if (la.kind == 21) {
- Get();
+ lexer.NextToken();
+
+#line 2493 "VBNET.ATG"
List typeArguments = new List(1);
if (typeref != null) typeArguments.Add(typeref);
typeref = new TypeReference("System.Nullable", typeArguments) { IsKeyword = true };
-
+
}
} else if (StartOf(12)) {
- PrimitiveTypeName(out name);
- typeref = new TypeReference(name, true);
+ PrimitiveTypeName(
+#line 2499 "VBNET.ATG"
+out name);
+
+#line 2499 "VBNET.ATG"
+ typeref = new TypeReference(name, true);
if (la.kind == 21) {
- Get();
+ lexer.NextToken();
+
+#line 2503 "VBNET.ATG"
List typeArguments = new List(1);
if (typeref != null) typeArguments.Add(typeref);
typeref = new TypeReference("System.Nullable", typeArguments) { IsKeyword = true };
-
+
}
} else SynErr(238);
}
- void EnumBody(TypeDeclaration newType) {
- FieldDeclaration f;
+ void EnumBody(
+#line 612 "VBNET.ATG"
+TypeDeclaration newType) {
+
+#line 613 "VBNET.ATG"
+ FieldDeclaration f;
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
while (StartOf(13)) {
- EnumMemberDecl(out f);
- compilationUnit.AddChild(f);
+ EnumMemberDecl(
+#line 616 "VBNET.ATG"
+out f);
+#line 618 "VBNET.ATG"
+ compilationUnit.AddChild(f);
+
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
}
Expect(100);
Expect(102);
- newType.EndLocation = t.EndLocation;
+
+#line 622 "VBNET.ATG"
+ newType.EndLocation = t.EndLocation;
EndOfStmt();
}
- void InterfaceBase(out List bases) {
+ void InterfaceBase(
+#line 1573 "VBNET.ATG"
+out List bases) {
+
+#line 1575 "VBNET.ATG"
TypeReference type;
bases = new List();
-
+
Expect(127);
- TypeName(out type);
- if (type != null) bases.Add(type);
+ TypeName(
+#line 1579 "VBNET.ATG"
+out type);
+
+#line 1579 "VBNET.ATG"
+ if (type != null) bases.Add(type);
while (la.kind == 12) {
- Get();
- TypeName(out type);
- if (type != null) bases.Add(type);
+ lexer.NextToken();
+ TypeName(
+#line 1582 "VBNET.ATG"
+out type);
+
+#line 1582 "VBNET.ATG"
+ if (type != null) bases.Add(type);
}
EndOfStmt();
}
- void InterfaceBody(TypeDeclaration newType) {
+ void InterfaceBody(
+#line 626 "VBNET.ATG"
+TypeDeclaration newType) {
while (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
@@ -832,115 +1274,169 @@ partial class Parser : AbstractParser
}
Expect(100);
Expect(129);
- newType.EndLocation = t.EndLocation;
+
+#line 632 "VBNET.ATG"
+ newType.EndLocation = t.EndLocation;
EndOfStmt();
}
- void FormalParameterList(List parameter) {
- ParameterDeclarationExpression p;
- FormalParameter(out p);
- if (p != null) parameter.Add(p);
+ void FormalParameterList(
+#line 2687 "VBNET.ATG"
+List parameter) {
+
+#line 2688 "VBNET.ATG"
+ ParameterDeclarationExpression p;
+ FormalParameter(
+#line 2690 "VBNET.ATG"
+out p);
+
+#line 2690 "VBNET.ATG"
+ if (p != null) parameter.Add(p);
while (la.kind == 12) {
- Get();
- FormalParameter(out p);
- if (p != null) parameter.Add(p);
+ lexer.NextToken();
+ FormalParameter(
+#line 2692 "VBNET.ATG"
+out p);
+
+#line 2692 "VBNET.ATG"
+ if (p != null) parameter.Add(p);
}
}
- void MemberModifier(ModifierList m) {
+ void MemberModifier(
+#line 3428 "VBNET.ATG"
+ModifierList m) {
switch (la.kind) {
- case 142: {
- Get();
+ case 143: {
+ lexer.NextToken();
+
+#line 3429 "VBNET.ATG"
m.Add(Modifiers.Abstract, t.Location);
break;
}
case 89: {
- Get();
+ lexer.NextToken();
+
+#line 3430 "VBNET.ATG"
m.Add(Modifiers.Default, t.Location);
break;
}
case 112: {
- Get();
+ lexer.NextToken();
+
+#line 3431 "VBNET.ATG"
m.Add(Modifiers.Internal, t.Location);
break;
}
- case 184: {
- Get();
+ case 185: {
+ lexer.NextToken();
+
+#line 3432 "VBNET.ATG"
m.Add(Modifiers.New, t.Location);
break;
}
- case 166: {
- Get();
+ case 167: {
+ lexer.NextToken();
+
+#line 3433 "VBNET.ATG"
m.Add(Modifiers.Override, t.Location);
break;
}
- case 143: {
- Get();
+ case 144: {
+ lexer.NextToken();
+
+#line 3434 "VBNET.ATG"
m.Add(Modifiers.Abstract, t.Location);
break;
}
- case 170: {
- Get();
+ case 171: {
+ lexer.NextToken();
+
+#line 3435 "VBNET.ATG"
m.Add(Modifiers.Private, t.Location);
break;
}
- case 172: {
- Get();
+ case 173: {
+ lexer.NextToken();
+
+#line 3436 "VBNET.ATG"
m.Add(Modifiers.Protected, t.Location);
break;
}
- case 173: {
- Get();
+ case 174: {
+ lexer.NextToken();
+
+#line 3437 "VBNET.ATG"
m.Add(Modifiers.Public, t.Location);
break;
}
- case 152: {
- Get();
+ case 153: {
+ lexer.NextToken();
+
+#line 3438 "VBNET.ATG"
m.Add(Modifiers.Sealed, t.Location);
break;
}
- case 153: {
- Get();
+ case 154: {
+ lexer.NextToken();
+
+#line 3439 "VBNET.ATG"
m.Add(Modifiers.Sealed, t.Location);
break;
}
- case 185: {
- Get();
+ case 186: {
+ lexer.NextToken();
+
+#line 3440 "VBNET.ATG"
m.Add(Modifiers.Static, t.Location);
break;
}
- case 165: {
- Get();
+ case 166: {
+ lexer.NextToken();
+
+#line 3441 "VBNET.ATG"
m.Add(Modifiers.Virtual, t.Location);
break;
}
- case 164: {
- Get();
+ case 165: {
+ lexer.NextToken();
+
+#line 3442 "VBNET.ATG"
m.Add(Modifiers.Overloads, t.Location);
break;
}
- case 175: {
- Get();
+ case 176: {
+ lexer.NextToken();
+
+#line 3443 "VBNET.ATG"
m.Add(Modifiers.ReadOnly, t.Location);
break;
}
- case 220: {
- Get();
+ case 221: {
+ lexer.NextToken();
+
+#line 3444 "VBNET.ATG"
m.Add(Modifiers.WriteOnly, t.Location);
break;
}
- case 219: {
- Get();
+ case 220: {
+ lexer.NextToken();
+
+#line 3445 "VBNET.ATG"
m.Add(Modifiers.WithEvents, t.Location);
break;
}
case 92: {
- Get();
+ lexer.NextToken();
+
+#line 3446 "VBNET.ATG"
m.Add(Modifiers.Dim, t.Location);
break;
}
- case 168: {
- Get();
+ case 169: {
+ lexer.NextToken();
+
+#line 3447 "VBNET.ATG"
m.Add(Modifiers.Partial, t.Location);
break;
}
@@ -948,53 +1444,83 @@ partial class Parser : AbstractParser
}
}
- void ClassMemberDecl(ModifierList m, List attributes) {
- StructureMemberDecl(m, attributes);
+ void ClassMemberDecl(
+#line 767 "VBNET.ATG"
+ModifierList m, List attributes) {
+ StructureMemberDecl(
+#line 768 "VBNET.ATG"
+m, attributes);
}
- void StructureMemberDecl(ModifierList m, List attributes) {
+ void StructureMemberDecl(
+#line 781 "VBNET.ATG"
+ModifierList m, List attributes) {
+
+#line 783 "VBNET.ATG"
TypeReference type = null;
List p = new List();
Statement stmt = null;
List variableDeclarators = new List();
List templates = new List();
-
+
switch (la.kind) {
- case 71: case 90: case 102: case 129: case 141: case 194: {
- NonModuleDeclaration(m, attributes);
+ case 71: case 90: case 102: case 129: case 142: case 195: {
+ NonModuleDeclaration(
+#line 790 "VBNET.ATG"
+m, attributes);
break;
}
- case 195: {
- Get();
- Location startPos = t.Location;
+ case 196: {
+ lexer.NextToken();
+#line 794 "VBNET.ATG"
+ Location startPos = t.Location;
+
if (StartOf(4)) {
+
+#line 798 "VBNET.ATG"
string name = String.Empty;
MethodDeclaration methodDeclaration; List handlesClause = null;
List implementsClause = null;
-
+
Identifier();
+
+#line 804 "VBNET.ATG"
name = t.val;
m.Check(Modifiers.VBMethods);
-
- TypeParameterList(templates);
+
+ TypeParameterList(
+#line 807 "VBNET.ATG"
+templates);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 808 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 121 || la.kind == 123) {
if (la.kind == 123) {
- ImplementsClause(out implementsClause);
+ ImplementsClause(
+#line 811 "VBNET.ATG"
+out implementsClause);
} else {
- HandlesClause(out handlesClause);
+ HandlesClause(
+#line 813 "VBNET.ATG"
+out handlesClause);
}
}
- Location endLocation = t.EndLocation;
- if (IsMustOverride(m)) {
+
+#line 816 "VBNET.ATG"
+ Location endLocation = t.EndLocation;
+ if (
+#line 819 "VBNET.ATG"
+IsMustOverride(m)) {
EndOfStmt();
+
+#line 822 "VBNET.ATG"
methodDeclaration = new MethodDeclaration {
Name = name, Modifier = m.Modifier, Parameters = p, Attributes = attributes,
StartLocation = m.GetDeclarationLocation(startPos), EndLocation = endLocation,
@@ -1004,9 +1530,11 @@ partial class Parser : AbstractParser
InterfaceImplementations = implementsClause
};
compilationUnit.AddChild(methodDeclaration);
-
+
} else if (la.kind == 1) {
- Get();
+ lexer.NextToken();
+
+#line 835 "VBNET.ATG"
methodDeclaration = new MethodDeclaration {
Name = name, Modifier = m.Modifier, Parameters = p, Attributes = attributes,
StartLocation = m.GetDeclarationLocation(startPos), EndLocation = endLocation,
@@ -1016,98 +1544,150 @@ partial class Parser : AbstractParser
InterfaceImplementations = implementsClause
};
compilationUnit.AddChild(methodDeclaration);
+
- if (ParseMethodBodies) {
- Block(out stmt);
+#line 846 "VBNET.ATG"
+ if (ParseMethodBodies) {
+ Block(
+#line 847 "VBNET.ATG"
+out stmt);
Expect(100);
- Expect(195);
+ Expect(196);
+
+#line 849 "VBNET.ATG"
} else {
// don't parse method body
lexer.SkipCurrentBlock(Tokens.Sub); stmt = new BlockStatement();
}
+
+
+#line 855 "VBNET.ATG"
+ methodDeclaration.Body = (BlockStatement)stmt;
- methodDeclaration.Body = (BlockStatement)stmt;
- methodDeclaration.Body.EndLocation = t.EndLocation;
+#line 856 "VBNET.ATG"
+ methodDeclaration.Body.EndLocation = t.EndLocation;
EndOfStmt();
} else SynErr(240);
- } else if (la.kind == 148) {
- Get();
+ } else if (la.kind == 149) {
+ lexer.NextToken();
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 860 "VBNET.ATG"
+p);
}
Expect(26);
}
- m.Check(Modifiers.Constructors);
- Location constructorEndLocation = t.EndLocation;
+
+#line 861 "VBNET.ATG"
+ m.Check(Modifiers.Constructors);
+
+#line 862 "VBNET.ATG"
+ Location constructorEndLocation = t.EndLocation;
Expect(1);
- if (ParseMethodBodies) {
- Block(out stmt);
+
+#line 865 "VBNET.ATG"
+ if (ParseMethodBodies) {
+ Block(
+#line 866 "VBNET.ATG"
+out stmt);
Expect(100);
- Expect(195);
+ Expect(196);
+
+#line 868 "VBNET.ATG"
} else {
// don't parse method body
lexer.SkipCurrentBlock(Tokens.Sub); stmt = new BlockStatement();
}
+
- Location endLocation = t.EndLocation;
+#line 874 "VBNET.ATG"
+ Location endLocation = t.EndLocation;
EndOfStmt();
+
+#line 877 "VBNET.ATG"
ConstructorDeclaration cd = new ConstructorDeclaration("New", m.Modifier, p, attributes);
cd.StartLocation = m.GetDeclarationLocation(startPos);
cd.EndLocation = constructorEndLocation;
cd.Body = (BlockStatement)stmt;
cd.Body.EndLocation = endLocation;
compilationUnit.AddChild(cd);
-
+
} else SynErr(241);
break;
}
case 114: {
- Get();
+ lexer.NextToken();
+
+#line 889 "VBNET.ATG"
m.Check(Modifiers.VBMethods);
string name = String.Empty;
Location startPos = t.Location;
MethodDeclaration methodDeclaration;List handlesClause = null;
List implementsClause = null;
AttributeSection returnTypeAttributeSection = null;
-
+
Identifier();
- name = t.val;
- TypeParameterList(templates);
+
+#line 896 "VBNET.ATG"
+ name = t.val;
+ TypeParameterList(
+#line 897 "VBNET.ATG"
+templates);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 898 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 50) {
- Get();
+ lexer.NextToken();
while (la.kind == 28) {
- AttributeSection(out returnTypeAttributeSection);
+ AttributeSection(
+#line 900 "VBNET.ATG"
+out returnTypeAttributeSection);
+
+#line 902 "VBNET.ATG"
if (returnTypeAttributeSection != null) {
returnTypeAttributeSection.AttributeTarget = "return";
attributes.Add(returnTypeAttributeSection);
}
-
+
}
- TypeName(out type);
+ TypeName(
+#line 908 "VBNET.ATG"
+out type);
}
+
+#line 910 "VBNET.ATG"
if(type == null) {
type = new TypeReference("System.Object", true);
}
-
+
if (la.kind == 121 || la.kind == 123) {
if (la.kind == 123) {
- ImplementsClause(out implementsClause);
+ ImplementsClause(
+#line 916 "VBNET.ATG"
+out implementsClause);
} else {
- HandlesClause(out handlesClause);
+ HandlesClause(
+#line 918 "VBNET.ATG"
+out handlesClause);
}
}
- Location endLocation = t.EndLocation;
- if (IsMustOverride(m)) {
+
+#line 921 "VBNET.ATG"
+ Location endLocation = t.EndLocation;
+ if (
+#line 924 "VBNET.ATG"
+IsMustOverride(m)) {
EndOfStmt();
+
+#line 927 "VBNET.ATG"
methodDeclaration = new MethodDeclaration {
Name = name, Modifier = m.Modifier, TypeReference = type,
Parameters = p, Attributes = attributes,
@@ -1117,11 +1697,13 @@ partial class Parser : AbstractParser
Templates = templates,
InterfaceImplementations = implementsClause
};
-
+
compilationUnit.AddChild(methodDeclaration);
-
+
} else if (la.kind == 1) {
- Get();
+ lexer.NextToken();
+
+#line 942 "VBNET.ATG"
methodDeclaration = new MethodDeclaration {
Name = name, Modifier = m.Modifier, TypeReference = type,
Parameters = p, Attributes = attributes,
@@ -1131,13 +1713,17 @@ partial class Parser : AbstractParser
HandlesClause = handlesClause,
InterfaceImplementations = implementsClause
};
-
+
compilationUnit.AddChild(methodDeclaration);
-
- if (ParseMethodBodies) {
- Block(out stmt);
+
+ if (ParseMethodBodies) {
+ Block(
+#line 955 "VBNET.ATG"
+out stmt);
Expect(100);
Expect(114);
+
+#line 957 "VBNET.ATG"
} else {
// don't parse method body
lexer.SkipCurrentBlock(Tokens.Function); stmt = new BlockStatement();
@@ -1145,105 +1731,143 @@ partial class Parser : AbstractParser
methodDeclaration.Body = (BlockStatement)stmt;
methodDeclaration.Body.StartLocation = methodDeclaration.EndLocation;
methodDeclaration.Body.EndLocation = t.EndLocation;
-
+
EndOfStmt();
} else SynErr(242);
break;
}
case 88: {
- Get();
+ lexer.NextToken();
+
+#line 971 "VBNET.ATG"
m.Check(Modifiers.VBExternalMethods);
Location startPos = t.Location;
CharsetModifier charsetModifer = CharsetModifier.None;
string library = String.Empty;
string alias = null;
string name = String.Empty;
-
+
if (StartOf(15)) {
- Charset(out charsetModifer);
+ Charset(
+#line 978 "VBNET.ATG"
+out charsetModifer);
}
- if (la.kind == 195) {
- Get();
+ if (la.kind == 196) {
+ lexer.NextToken();
Identifier();
- name = t.val;
- Expect(135);
+
+#line 981 "VBNET.ATG"
+ name = t.val;
+ Expect(136);
Expect(3);
- library = t.literalValue as string;
+
+#line 982 "VBNET.ATG"
+ library = t.literalValue as string;
if (la.kind == 46) {
- Get();
+ lexer.NextToken();
Expect(3);
- alias = t.literalValue as string;
+
+#line 983 "VBNET.ATG"
+ alias = t.literalValue as string;
}
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 984 "VBNET.ATG"
+p);
}
Expect(26);
}
EndOfStmt();
+
+#line 987 "VBNET.ATG"
DeclareDeclaration declareDeclaration = new DeclareDeclaration(name, m.Modifier, null, p, attributes, library, alias, charsetModifer);
declareDeclaration.StartLocation = m.GetDeclarationLocation(startPos);
declareDeclaration.EndLocation = t.EndLocation;
compilationUnit.AddChild(declareDeclaration);
-
+
} else if (la.kind == 114) {
- Get();
+ lexer.NextToken();
Identifier();
- name = t.val;
- Expect(135);
+
+#line 994 "VBNET.ATG"
+ name = t.val;
+ Expect(136);
Expect(3);
- library = t.literalValue as string;
+
+#line 995 "VBNET.ATG"
+ library = t.literalValue as string;
if (la.kind == 46) {
- Get();
+ lexer.NextToken();
Expect(3);
- alias = t.literalValue as string;
+
+#line 996 "VBNET.ATG"
+ alias = t.literalValue as string;
}
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 997 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 998 "VBNET.ATG"
+out type);
}
EndOfStmt();
+
+#line 1001 "VBNET.ATG"
DeclareDeclaration declareDeclaration = new DeclareDeclaration(name, m.Modifier, type, p, attributes, library, alias, charsetModifer);
declareDeclaration.StartLocation = m.GetDeclarationLocation(startPos);
declareDeclaration.EndLocation = t.EndLocation;
compilationUnit.AddChild(declareDeclaration);
-
+
} else SynErr(243);
break;
}
case 106: {
- Get();
+ lexer.NextToken();
+
+#line 1011 "VBNET.ATG"
m.Check(Modifiers.VBEvents);
Location startPos = t.Location;
EventDeclaration eventDeclaration;
string name = String.Empty;
List implementsClause = null;
-
+
Identifier();
- name= t.val;
+
+#line 1017 "VBNET.ATG"
+ name= t.val;
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 1019 "VBNET.ATG"
+out type);
} else if (StartOf(16)) {
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 1021 "VBNET.ATG"
+p);
}
Expect(26);
}
} else SynErr(244);
if (la.kind == 123) {
- ImplementsClause(out implementsClause);
+ ImplementsClause(
+#line 1023 "VBNET.ATG"
+out implementsClause);
}
+
+#line 1025 "VBNET.ATG"
eventDeclaration = new EventDeclaration {
Name = name, TypeReference = type, Modifier = m.Modifier,
Parameters = p, Attributes = attributes, InterfaceImplementations = implementsClause,
@@ -1251,99 +1875,151 @@ partial class Parser : AbstractParser
EndLocation = t.EndLocation
};
compilationUnit.AddChild(eventDeclaration);
-
+
EndOfStmt();
break;
}
- case 2: case 45: case 49: case 51: case 52: case 53: case 54: case 57: case 74: case 91: case 94: case 103: case 108: case 113: case 120: case 126: case 130: case 133: case 156: case 162: case 169: case 188: case 197: case 198: case 208: case 209: case 215: {
+ case 2: case 45: case 49: case 51: case 52: case 53: case 54: case 57: case 74: case 91: case 94: case 103: case 108: case 113: case 120: case 126: case 130: case 133: case 157: case 163: case 170: case 189: case 198: case 199: case 209: case 210: case 216: {
+
+#line 1036 "VBNET.ATG"
m.Check(Modifiers.Fields);
FieldDeclaration fd = new FieldDeclaration(attributes, null, m.Modifier);
-
+
IdentifierForFieldDeclaration();
- string name = t.val;
- fd.StartLocation = m.GetDeclarationLocation(t.Location);
- VariableDeclaratorPartAfterIdentifier(variableDeclarators, name);
+
+#line 1039 "VBNET.ATG"
+ string name = t.val;
+
+#line 1040 "VBNET.ATG"
+ fd.StartLocation = m.GetDeclarationLocation(t.Location);
+ VariableDeclaratorPartAfterIdentifier(
+#line 1042 "VBNET.ATG"
+variableDeclarators, name);
while (la.kind == 12) {
- Get();
- VariableDeclarator(variableDeclarators);
+ lexer.NextToken();
+ VariableDeclarator(
+#line 1043 "VBNET.ATG"
+variableDeclarators);
}
EndOfStmt();
+
+#line 1046 "VBNET.ATG"
fd.EndLocation = t.EndLocation;
fd.Fields = variableDeclarators;
compilationUnit.AddChild(fd);
-
+
break;
}
case 75: {
- m.Check(Modifiers.Fields);
- Get();
- m.Add(Modifiers.Const, t.Location);
+
+#line 1051 "VBNET.ATG"
+ m.Check(Modifiers.Fields);
+ lexer.NextToken();
+
+#line 1052 "VBNET.ATG"
+ m.Add(Modifiers.Const, t.Location);
+
+#line 1054 "VBNET.ATG"
FieldDeclaration fd = new FieldDeclaration(attributes, type, m.Modifier);
fd.StartLocation = m.GetDeclarationLocation(t.Location);
List constantDeclarators = new List();
-
- ConstantDeclarator(constantDeclarators);
+
+ ConstantDeclarator(
+#line 1058 "VBNET.ATG"
+constantDeclarators);
while (la.kind == 12) {
- Get();
- ConstantDeclarator(constantDeclarators);
+ lexer.NextToken();
+ ConstantDeclarator(
+#line 1059 "VBNET.ATG"
+constantDeclarators);
}
+
+#line 1061 "VBNET.ATG"
fd.Fields = constantDeclarators;
fd.EndLocation = t.Location;
-
+
EndOfStmt();
+
+#line 1066 "VBNET.ATG"
fd.EndLocation = t.EndLocation;
compilationUnit.AddChild(fd);
-
+
break;
}
- case 171: {
- Get();
+ case 172: {
+ lexer.NextToken();
+
+#line 1072 "VBNET.ATG"
m.Check(Modifiers.VBProperties);
Location startPos = t.Location;
List implementsClause = null;
AttributeSection returnTypeAttributeSection = null;
Expression initializer = null;
-
+
Identifier();
- string propertyName = t.val;
+
+#line 1078 "VBNET.ATG"
+ string propertyName = t.val;
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 1079 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 50) {
- Get();
+ lexer.NextToken();
while (la.kind == 28) {
- AttributeSection(out returnTypeAttributeSection);
+ AttributeSection(
+#line 1082 "VBNET.ATG"
+out returnTypeAttributeSection);
+
+#line 1084 "VBNET.ATG"
if (returnTypeAttributeSection != null) {
returnTypeAttributeSection.AttributeTarget = "return";
attributes.Add(returnTypeAttributeSection);
}
-
+
}
- if (IsNewExpression()) {
- ObjectCreateExpression(out initializer);
+ if (
+#line 1091 "VBNET.ATG"
+IsNewExpression()) {
+ ObjectCreateExpression(
+#line 1091 "VBNET.ATG"
+out initializer);
+
+#line 1093 "VBNET.ATG"
if (initializer is ObjectCreateExpression) {
type = ((ObjectCreateExpression)initializer).CreateType.Clone();
} else {
type = ((ArrayCreateExpression)initializer).CreateType.Clone();
}
-
+
} else if (StartOf(8)) {
- TypeName(out type);
+ TypeName(
+#line 1100 "VBNET.ATG"
+out type);
} else SynErr(245);
}
if (la.kind == 10) {
- Get();
- Expr(out initializer);
+ lexer.NextToken();
+ Expr(
+#line 1103 "VBNET.ATG"
+out initializer);
}
if (la.kind == 123) {
- ImplementsClause(out implementsClause);
+ ImplementsClause(
+#line 1104 "VBNET.ATG"
+out implementsClause);
}
EndOfStmt();
- if (IsMustOverride(m) || IsAutomaticProperty()) {
+ if (
+#line 1108 "VBNET.ATG"
+IsMustOverride(m) || IsAutomaticProperty()) {
+
+#line 1110 "VBNET.ATG"
PropertyDeclaration pDecl = new PropertyDeclaration(propertyName, type, m.Modifier, attributes);
pDecl.StartLocation = m.GetDeclarationLocation(startPos);
pDecl.EndLocation = t.Location;
@@ -1353,8 +2029,10 @@ partial class Parser : AbstractParser
if (initializer != null)
pDecl.Initializer = initializer;
compilationUnit.AddChild(pDecl);
-
+
} else if (StartOf(17)) {
+
+#line 1122 "VBNET.ATG"
PropertyDeclaration pDecl = new PropertyDeclaration(propertyName, type, m.Modifier, attributes);
pDecl.StartLocation = m.GetDeclarationLocation(startPos);
pDecl.EndLocation = t.Location;
@@ -1364,40 +2042,58 @@ partial class Parser : AbstractParser
pDecl.Parameters = p;
PropertyGetRegion getRegion;
PropertySetRegion setRegion;
-
- AccessorDecls(out getRegion, out setRegion);
+
+ AccessorDecls(
+#line 1132 "VBNET.ATG"
+out getRegion, out setRegion);
Expect(100);
- Expect(171);
+ Expect(172);
EndOfStmt();
+
+#line 1136 "VBNET.ATG"
pDecl.GetRegion = getRegion;
pDecl.SetRegion = setRegion;
pDecl.BodyEnd = t.Location; // t = EndOfStmt; not "Property"
compilationUnit.AddChild(pDecl);
-
+
} else SynErr(246);
break;
}
case 85: {
- Get();
- Location startPos = t.Location;
+ lexer.NextToken();
+
+#line 1143 "VBNET.ATG"
+ Location startPos = t.Location;
Expect(106);
+
+#line 1145 "VBNET.ATG"
m.Check(Modifiers.VBCustomEvents);
EventAddRemoveRegion eventAccessorDeclaration;
EventAddRegion addHandlerAccessorDeclaration = null;
EventRemoveRegion removeHandlerAccessorDeclaration = null;
EventRaiseRegion raiseEventAccessorDeclaration = null;
List implementsClause = null;
-
+
Identifier();
- string customEventName = t.val;
+
+#line 1152 "VBNET.ATG"
+ string customEventName = t.val;
Expect(50);
- TypeName(out type);
+ TypeName(
+#line 1153 "VBNET.ATG"
+out type);
if (la.kind == 123) {
- ImplementsClause(out implementsClause);
+ ImplementsClause(
+#line 1154 "VBNET.ATG"
+out implementsClause);
}
EndOfStmt();
while (StartOf(18)) {
- EventAccessorDeclaration(out eventAccessorDeclaration);
+ EventAccessorDeclaration(
+#line 1157 "VBNET.ATG"
+out eventAccessorDeclaration);
+
+#line 1159 "VBNET.ATG"
if(eventAccessorDeclaration is EventAddRegion)
{
addHandlerAccessorDeclaration = (EventAddRegion)eventAccessorDeclaration;
@@ -1410,51 +2106,61 @@ partial class Parser : AbstractParser
{
raiseEventAccessorDeclaration = (EventRaiseRegion)eventAccessorDeclaration;
}
-
+
}
Expect(100);
Expect(106);
EndOfStmt();
+
+#line 1175 "VBNET.ATG"
if(addHandlerAccessorDeclaration == null)
{
Error("Need to provide AddHandler accessor.");
}
-
+
if(removeHandlerAccessorDeclaration == null)
{
Error("Need to provide RemoveHandler accessor.");
}
-
+
if(raiseEventAccessorDeclaration == null)
{
Error("Need to provide RaiseEvent accessor.");
}
-
- EventDeclaration decl = new EventDeclaration {
- TypeReference = type, Name = customEventName, Modifier = m.Modifier,
- Attributes = attributes,
- StartLocation = m.GetDeclarationLocation(startPos),
- EndLocation = t.EndLocation,
- AddRegion = addHandlerAccessorDeclaration,
- RemoveRegion = removeHandlerAccessorDeclaration,
- RaiseRegion = raiseEventAccessorDeclaration
- };
- compilationUnit.AddChild(decl);
-
+
+ EventDeclaration decl = new EventDeclaration {
+ TypeReference = type, Name = customEventName, Modifier = m.Modifier,
+ Attributes = attributes,
+ StartLocation = m.GetDeclarationLocation(startPos),
+ EndLocation = t.EndLocation,
+ AddRegion = addHandlerAccessorDeclaration,
+ RemoveRegion = removeHandlerAccessorDeclaration,
+ RaiseRegion = raiseEventAccessorDeclaration
+ };
+ compilationUnit.AddChild(decl);
+
break;
}
- case 147: case 158: case 217: {
- ConversionType opConversionType = ConversionType.None;
- if (la.kind == 147 || la.kind == 217) {
- if (la.kind == 217) {
- Get();
- opConversionType = ConversionType.Implicit;
+ case 148: case 159: case 218: {
+
+#line 1201 "VBNET.ATG"
+ ConversionType opConversionType = ConversionType.None;
+ if (la.kind == 148 || la.kind == 218) {
+ if (la.kind == 218) {
+ lexer.NextToken();
+
+#line 1202 "VBNET.ATG"
+ opConversionType = ConversionType.Implicit;
} else {
- Get();
+ lexer.NextToken();
+
+#line 1203 "VBNET.ATG"
opConversionType = ConversionType.Explicit;
}
}
- Expect(158);
+ Expect(159);
+
+#line 1206 "VBNET.ATG"
m.Check(Modifiers.VBOperators);
Location startPos = t.Location;
TypeReference returnType = NullTypeReference.Instance;
@@ -1463,51 +2169,79 @@ partial class Parser : AbstractParser
OverloadableOperatorType operatorType;
AttributeSection section;
List parameters = new List();
-
- OverloadableOperator(out operatorType);
+
+ OverloadableOperator(
+#line 1215 "VBNET.ATG"
+out operatorType);
Expect(25);
if (la.kind == 59) {
- Get();
+ lexer.NextToken();
}
Identifier();
- operandName = t.val;
+
+#line 1216 "VBNET.ATG"
+ operandName = t.val;
if (la.kind == 50) {
- Get();
- TypeName(out operandType);
+ lexer.NextToken();
+ TypeName(
+#line 1217 "VBNET.ATG"
+out operandType);
}
- parameters.Add(new ParameterDeclarationExpression(operandType, operandName, ParameterModifiers.In));
+
+#line 1218 "VBNET.ATG"
+ parameters.Add(new ParameterDeclarationExpression(operandType, operandName, ParameterModifiers.In));
while (la.kind == 12) {
- Get();
+ lexer.NextToken();
if (la.kind == 59) {
- Get();
+ lexer.NextToken();
}
Identifier();
- operandName = t.val;
+
+#line 1222 "VBNET.ATG"
+ operandName = t.val;
if (la.kind == 50) {
- Get();
- TypeName(out operandType);
+ lexer.NextToken();
+ TypeName(
+#line 1223 "VBNET.ATG"
+out operandType);
}
- parameters.Add(new ParameterDeclarationExpression(operandType, operandName, ParameterModifiers.In));
+
+#line 1224 "VBNET.ATG"
+ parameters.Add(new ParameterDeclarationExpression(operandType, operandName, ParameterModifiers.In));
}
Expect(26);
- Location endPos = t.EndLocation;
+
+#line 1227 "VBNET.ATG"
+ Location endPos = t.EndLocation;
if (la.kind == 50) {
- Get();
+ lexer.NextToken();
while (la.kind == 28) {
- AttributeSection(out section);
+ AttributeSection(
+#line 1228 "VBNET.ATG"
+out section);
+
+#line 1229 "VBNET.ATG"
if (section != null) {
section.AttributeTarget = "return";
attributes.Add(section);
- }
+ }
}
- TypeName(out returnType);
- endPos = t.EndLocation;
+ TypeName(
+#line 1233 "VBNET.ATG"
+out returnType);
+
+#line 1233 "VBNET.ATG"
+ endPos = t.EndLocation;
}
Expect(1);
- Block(out stmt);
+ Block(
+#line 1235 "VBNET.ATG"
+out stmt);
Expect(100);
- Expect(158);
+ Expect(159);
EndOfStmt();
+
+#line 1237 "VBNET.ATG"
OperatorDeclaration operatorDeclaration = new OperatorDeclaration {
Modifier = m.Modifier,
Attributes = attributes,
@@ -1522,37 +2256,53 @@ partial class Parser : AbstractParser
operatorDeclaration.Body.StartLocation = startPos;
operatorDeclaration.Body.EndLocation = t.Location;
compilationUnit.AddChild(operatorDeclaration);
-
+
break;
}
default: SynErr(247); break;
}
}
- void EnumMemberDecl(out FieldDeclaration f) {
+ void EnumMemberDecl(
+#line 749 "VBNET.ATG"
+out FieldDeclaration f) {
+
+#line 751 "VBNET.ATG"
Expression expr = null;List attributes = new List();
AttributeSection section = null;
VariableDeclaration varDecl = null;
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 755 "VBNET.ATG"
+out section);
+
+#line 755 "VBNET.ATG"
+ attributes.Add(section);
}
Identifier();
+
+#line 758 "VBNET.ATG"
f = new FieldDeclaration(attributes);
varDecl = new VariableDeclaration(t.val);
f.Fields.Add(varDecl);
f.StartLocation = varDecl.StartLocation = t.Location;
-
+
if (la.kind == 10) {
- Get();
- Expr(out expr);
- varDecl.Initializer = expr;
+ lexer.NextToken();
+ Expr(
+#line 763 "VBNET.ATG"
+out expr);
+
+#line 763 "VBNET.ATG"
+ varDecl.Initializer = expr;
}
EndOfStmt();
}
void InterfaceMemberDecl() {
+
+#line 640 "VBNET.ATG"
TypeReference type =null;
List p = new List();
List templates = new List();
@@ -1560,57 +2310,83 @@ partial class Parser : AbstractParser
ModifierList mod = new ModifierList();
List attributes = new List();
string name;
-
+
if (StartOf(19)) {
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 648 "VBNET.ATG"
+out section);
+
+#line 648 "VBNET.ATG"
+ attributes.Add(section);
}
while (StartOf(10)) {
- MemberModifier(mod);
+ MemberModifier(
+#line 651 "VBNET.ATG"
+mod);
}
if (la.kind == 106) {
- Get();
+ lexer.NextToken();
+
+#line 655 "VBNET.ATG"
mod.Check(Modifiers.VBInterfaceEvents);
Location startLocation = t.Location;
-
+
Identifier();
- name = t.val;
+
+#line 658 "VBNET.ATG"
+ name = t.val;
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 659 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 660 "VBNET.ATG"
+out type);
}
EndOfStmt();
+
+#line 663 "VBNET.ATG"
EventDeclaration ed = new EventDeclaration {
Name = name, TypeReference = type, Modifier = mod.Modifier,
Parameters = p, Attributes = attributes,
StartLocation = startLocation, EndLocation = t.EndLocation
};
compilationUnit.AddChild(ed);
+
+ } else if (la.kind == 196) {
+ lexer.NextToken();
- } else if (la.kind == 195) {
- Get();
+#line 673 "VBNET.ATG"
Location startLocation = t.Location;
mod.Check(Modifiers.VBInterfaceMethods);
-
+
Identifier();
- name = t.val;
- TypeParameterList(templates);
+
+#line 676 "VBNET.ATG"
+ name = t.val;
+ TypeParameterList(
+#line 677 "VBNET.ATG"
+templates);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 678 "VBNET.ATG"
+p);
}
Expect(26);
}
EndOfStmt();
+
+#line 681 "VBNET.ATG"
MethodDeclaration md = new MethodDeclaration {
Name = name,
Modifier = mod.Modifier,
@@ -1622,29 +2398,43 @@ partial class Parser : AbstractParser
Templates = templates
};
compilationUnit.AddChild(md);
-
+
} else if (la.kind == 114) {
- Get();
+ lexer.NextToken();
+
+#line 696 "VBNET.ATG"
mod.Check(Modifiers.VBInterfaceMethods);
Location startLocation = t.Location;
-
+
Identifier();
- name = t.val;
- TypeParameterList(templates);
+
+#line 699 "VBNET.ATG"
+ name = t.val;
+ TypeParameterList(
+#line 700 "VBNET.ATG"
+templates);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 701 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 50) {
- Get();
+ lexer.NextToken();
while (la.kind == 28) {
- AttributeSection(out returnTypeAttributeSection);
+ AttributeSection(
+#line 702 "VBNET.ATG"
+out returnTypeAttributeSection);
}
- TypeName(out type);
+ TypeName(
+#line 702 "VBNET.ATG"
+out type);
}
+
+#line 704 "VBNET.ATG"
if(type == null) {
type = new TypeReference("System.Object", true);
}
@@ -1660,262 +2450,360 @@ partial class Parser : AbstractParser
md.EndLocation = t.EndLocation;
md.Templates = templates;
compilationUnit.AddChild(md);
-
+
EndOfStmt();
- } else if (la.kind == 171) {
- Get();
+ } else if (la.kind == 172) {
+ lexer.NextToken();
+
+#line 724 "VBNET.ATG"
Location startLocation = t.Location;
mod.Check(Modifiers.VBInterfaceProperties);
-
+
Identifier();
- name = t.val;
+
+#line 727 "VBNET.ATG"
+ name = t.val;
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 728 "VBNET.ATG"
+p);
}
Expect(26);
}
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 729 "VBNET.ATG"
+out type);
}
+
+#line 731 "VBNET.ATG"
if(type == null) {
type = new TypeReference("System.Object", true);
}
-
+
EndOfStmt();
+
+#line 737 "VBNET.ATG"
PropertyDeclaration pd = new PropertyDeclaration(name, type, mod.Modifier, attributes);
pd.Parameters = p;
pd.EndLocation = t.EndLocation;
pd.StartLocation = startLocation;
compilationUnit.AddChild(pd);
-
+
} else SynErr(248);
} else if (StartOf(20)) {
- NonModuleDeclaration(mod, attributes);
+ NonModuleDeclaration(
+#line 745 "VBNET.ATG"
+mod, attributes);
} else SynErr(249);
}
- void Expr(out Expression expr) {
- expr = null;
- if (IsQueryExpression()) {
- QueryExpr(out expr);
+ void Expr(
+#line 1632 "VBNET.ATG"
+out Expression expr) {
+
+#line 1633 "VBNET.ATG"
+ expr = null;
+ if (
+#line 1634 "VBNET.ATG"
+IsQueryExpression() ) {
+ QueryExpr(
+#line 1635 "VBNET.ATG"
+out expr);
} else if (la.kind == 114) {
- LambdaExpr(out expr);
+ LambdaExpr(
+#line 1636 "VBNET.ATG"
+out expr);
} else if (StartOf(21)) {
- DisjunctionExpr(out expr);
+ DisjunctionExpr(
+#line 1637 "VBNET.ATG"
+out expr);
} else SynErr(250);
}
- void ImplementsClause(out List baseInterfaces) {
+ void ImplementsClause(
+#line 1605 "VBNET.ATG"
+out List baseInterfaces) {
+
+#line 1607 "VBNET.ATG"
baseInterfaces = new List();
TypeReference type = null;
string memberName = null;
-
+
Expect(123);
- NonArrayTypeName(out type, false);
- if (type != null) memberName = TypeReference.StripLastIdentifierFromType(ref type);
- baseInterfaces.Add(new InterfaceImplementation(type, memberName));
+ NonArrayTypeName(
+#line 1612 "VBNET.ATG"
+out type, false);
+
+#line 1613 "VBNET.ATG"
+ if (type != null) memberName = TypeReference.StripLastIdentifierFromType(ref type);
+
+#line 1614 "VBNET.ATG"
+ baseInterfaces.Add(new InterfaceImplementation(type, memberName));
while (la.kind == 12) {
- Get();
- NonArrayTypeName(out type, false);
- if (type != null) memberName = TypeReference.StripLastIdentifierFromType(ref type);
- baseInterfaces.Add(new InterfaceImplementation(type, memberName));
+ lexer.NextToken();
+ NonArrayTypeName(
+#line 1616 "VBNET.ATG"
+out type, false);
+
+#line 1617 "VBNET.ATG"
+ if (type != null) memberName = TypeReference.StripLastIdentifierFromType(ref type);
+
+#line 1618 "VBNET.ATG"
+ baseInterfaces.Add(new InterfaceImplementation(type, memberName));
}
}
- void HandlesClause(out List handlesClause) {
+ void HandlesClause(
+#line 1563 "VBNET.ATG"
+out List handlesClause) {
+
+#line 1565 "VBNET.ATG"
handlesClause = new List();
string name;
-
+
Expect(121);
- EventMemberSpecifier(out name);
- if (name != null) handlesClause.Add(name);
+ EventMemberSpecifier(
+#line 1568 "VBNET.ATG"
+out name);
+
+#line 1568 "VBNET.ATG"
+ if (name != null) handlesClause.Add(name);
while (la.kind == 12) {
- Get();
- EventMemberSpecifier(out name);
- if (name != null) handlesClause.Add(name);
+ lexer.NextToken();
+ EventMemberSpecifier(
+#line 1569 "VBNET.ATG"
+out name);
+
+#line 1569 "VBNET.ATG"
+ if (name != null) handlesClause.Add(name);
}
}
- void Block(out Statement stmt) {
+ void Block(
+#line 2734 "VBNET.ATG"
+out Statement stmt) {
+
+#line 2737 "VBNET.ATG"
BlockStatement blockStmt = new BlockStatement();
/* in snippet parsing mode, t might be null */
if (t != null) blockStmt.StartLocation = t.EndLocation;
compilationUnit.BlockStart(blockStmt);
-
- while (StartOf(22)) {
- if (IsEndStmtAhead()) {
+
+ while (StartOf(22) ||
+#line 2743 "VBNET.ATG"
+IsEndStmtAhead()) {
+ if (
+#line 2743 "VBNET.ATG"
+IsEndStmtAhead()) {
Expect(100);
EndOfStmt();
- compilationUnit.AddChild(new EndStatement());
+
+#line 2743 "VBNET.ATG"
+ compilationUnit.AddChild(new EndStatement());
} else {
Statement();
EndOfStmt();
}
}
+
+#line 2748 "VBNET.ATG"
stmt = blockStmt;
if (t != null) blockStmt.EndLocation = t.EndLocation;
compilationUnit.BlockEnd();
-
+
}
- void Charset(out CharsetModifier charsetModifier) {
- charsetModifier = CharsetModifier.None;
- if (la.kind == 114 || la.kind == 195) {
+ void Charset(
+#line 1555 "VBNET.ATG"
+out CharsetModifier charsetModifier) {
+
+#line 1556 "VBNET.ATG"
+ charsetModifier = CharsetModifier.None;
+ if (la.kind == 114 || la.kind == 196) {
} else if (la.kind == 49) {
- Get();
- charsetModifier = CharsetModifier.Ansi;
+ lexer.NextToken();
+
+#line 1557 "VBNET.ATG"
+ charsetModifier = CharsetModifier.Ansi;
} else if (la.kind == 53) {
- Get();
- charsetModifier = CharsetModifier.Auto;
- } else if (la.kind == 208) {
- Get();
- charsetModifier = CharsetModifier.Unicode;
+ lexer.NextToken();
+
+#line 1558 "VBNET.ATG"
+ charsetModifier = CharsetModifier.Auto;
+ } else if (la.kind == 209) {
+ lexer.NextToken();
+
+#line 1559 "VBNET.ATG"
+ charsetModifier = CharsetModifier.Unicode;
} else SynErr(251);
}
void IdentifierForFieldDeclaration() {
switch (la.kind) {
case 2: {
- Get();
+ lexer.NextToken();
break;
}
case 45: {
- Get();
+ lexer.NextToken();
break;
}
case 49: {
- Get();
+ lexer.NextToken();
break;
}
case 51: {
- Get();
+ lexer.NextToken();
break;
}
case 52: {
- Get();
+ lexer.NextToken();
break;
}
case 53: {
- Get();
+ lexer.NextToken();
break;
}
case 54: {
- Get();
+ lexer.NextToken();
break;
}
case 57: {
- Get();
+ lexer.NextToken();
break;
}
case 74: {
- Get();
+ lexer.NextToken();
break;
}
case 91: {
- Get();
+ lexer.NextToken();
break;
}
case 94: {
- Get();
+ lexer.NextToken();
break;
}
case 103: {
- Get();
+ lexer.NextToken();
break;
}
case 108: {
- Get();
+ lexer.NextToken();
break;
}
case 113: {
- Get();
+ lexer.NextToken();
break;
}
case 120: {
- Get();
+ lexer.NextToken();
break;
}
case 126: {
- Get();
+ lexer.NextToken();
break;
}
case 130: {
- Get();
+ lexer.NextToken();
break;
}
case 133: {
- Get();
- break;
- }
- case 156: {
- Get();
+ lexer.NextToken();
break;
}
- case 162: {
- Get();
+ case 157: {
+ lexer.NextToken();
break;
}
- case 169: {
- Get();
+ case 163: {
+ lexer.NextToken();
break;
}
- case 188: {
- Get();
+ case 170: {
+ lexer.NextToken();
break;
}
- case 197: {
- Get();
+ case 189: {
+ lexer.NextToken();
break;
}
case 198: {
- Get();
+ lexer.NextToken();
break;
}
- case 208: {
- Get();
+ case 199: {
+ lexer.NextToken();
break;
}
case 209: {
- Get();
+ lexer.NextToken();
+ break;
+ }
+ case 210: {
+ lexer.NextToken();
break;
}
- case 215: {
- Get();
+ case 216: {
+ lexer.NextToken();
break;
}
default: SynErr(252); break;
}
}
- void VariableDeclaratorPartAfterIdentifier(List fieldDeclaration, string name) {
+ void VariableDeclaratorPartAfterIdentifier(
+#line 1440 "VBNET.ATG"
+List fieldDeclaration, string name) {
+
+#line 1442 "VBNET.ATG"
Expression expr = null;
TypeReference type = null;
ArrayList rank = null;
List dimension = null;
Location startLocation = t.Location;
-
- if (IsSize() && !IsDims()) {
- ArrayInitializationModifier(out dimension);
- }
- if (IsDims()) {
- ArrayNameModifier(out rank);
- }
- if (IsObjectCreation()) {
+
+ if (
+#line 1448 "VBNET.ATG"
+IsSize() && !IsDims()) {
+ ArrayInitializationModifier(
+#line 1448 "VBNET.ATG"
+out dimension);
+ }
+ if (
+#line 1449 "VBNET.ATG"
+IsDims()) {
+ ArrayNameModifier(
+#line 1449 "VBNET.ATG"
+out rank);
+ }
+ if (
+#line 1451 "VBNET.ATG"
+IsObjectCreation()) {
Expect(50);
- ObjectCreateExpression(out expr);
+ ObjectCreateExpression(
+#line 1451 "VBNET.ATG"
+out expr);
+
+#line 1453 "VBNET.ATG"
if (expr is ObjectCreateExpression) {
type = ((ObjectCreateExpression)expr).CreateType.Clone();
} else {
type = ((ArrayCreateExpression)expr).CreateType.Clone();
}
-
+
} else if (StartOf(23)) {
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 1460 "VBNET.ATG"
+out type);
+
+#line 1462 "VBNET.ATG"
if (type != null) {
for (int i = fieldDeclaration.Count - 1; i >= 0; i--) {
VariableDeclaration vd = fieldDeclaration[i];
@@ -1925,8 +2813,10 @@ partial class Parser : AbstractParser
vd.TypeReference = newType;
}
}
-
+
}
+
+#line 1474 "VBNET.ATG"
if (type == null && (dimension != null || rank != null)) {
type = new TypeReference("");
}
@@ -1949,72 +2839,116 @@ partial class Parser : AbstractParser
type.RankSpecifier = (int[])rank.ToArray(typeof(int));
}
}
-
+
if (la.kind == 10) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 1497 "VBNET.ATG"
+out expr);
}
} else SynErr(253);
+
+#line 1500 "VBNET.ATG"
VariableDeclaration varDecl = new VariableDeclaration(name, expr, type);
varDecl.StartLocation = startLocation;
varDecl.EndLocation = t.Location;
fieldDeclaration.Add(varDecl);
-
+
}
- void VariableDeclarator(List fieldDeclaration) {
+ void VariableDeclarator(
+#line 1434 "VBNET.ATG"
+List fieldDeclaration) {
Identifier();
- string name = t.val;
- VariableDeclaratorPartAfterIdentifier(fieldDeclaration, name);
+
+#line 1436 "VBNET.ATG"
+ string name = t.val;
+ VariableDeclaratorPartAfterIdentifier(
+#line 1437 "VBNET.ATG"
+fieldDeclaration, name);
}
- void ConstantDeclarator(List constantDeclaration) {
+ void ConstantDeclarator(
+#line 1415 "VBNET.ATG"
+List constantDeclaration) {
+
+#line 1417 "VBNET.ATG"
Expression expr = null;
TypeReference type = null;
string name = String.Empty;
Location location;
-
+
Identifier();
- name = t.val; location = t.Location;
+
+#line 1422 "VBNET.ATG"
+ name = t.val; location = t.Location;
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 1423 "VBNET.ATG"
+out type);
}
Expect(10);
- Expr(out expr);
+ Expr(
+#line 1424 "VBNET.ATG"
+out expr);
+
+#line 1426 "VBNET.ATG"
VariableDeclaration f = new VariableDeclaration(name, expr);
f.TypeReference = type;
f.StartLocation = location;
constantDeclaration.Add(f);
-
+
}
- void ObjectCreateExpression(out Expression oce) {
+ void ObjectCreateExpression(
+#line 1962 "VBNET.ATG"
+out Expression oce) {
+
+#line 1964 "VBNET.ATG"
TypeReference type = null;
CollectionInitializerExpression initializer = null;
List arguments = null;
ArrayList dimensions = null;
oce = null;
bool canBeNormal; bool canBeReDim;
-
- Expect(148);
+
+ Expect(149);
if (StartOf(8)) {
- NonArrayTypeName(out type, false);
+ NonArrayTypeName(
+#line 1972 "VBNET.ATG"
+out type, false);
if (la.kind == 25) {
- Get();
- NormalOrReDimArgumentList(out arguments, out canBeNormal, out canBeReDim);
+ lexer.NextToken();
+ NormalOrReDimArgumentList(
+#line 1973 "VBNET.ATG"
+out arguments, out canBeNormal, out canBeReDim);
Expect(26);
- if (la.kind == 23 || la.kind == 25) {
- if (la.kind == Tokens.OpenParenthesis) {
- ArrayTypeModifiers(out dimensions);
- CollectionInitializer(out initializer);
+ if (la.kind == 23 ||
+#line 1974 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis) {
+ if (
+#line 1974 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis) {
+ ArrayTypeModifiers(
+#line 1975 "VBNET.ATG"
+out dimensions);
+ CollectionInitializer(
+#line 1976 "VBNET.ATG"
+out initializer);
} else {
- CollectionInitializer(out initializer);
+ CollectionInitializer(
+#line 1977 "VBNET.ATG"
+out initializer);
}
}
- if (canBeReDim && !canBeNormal && initializer == null) initializer = new CollectionInitializerExpression();
+
+#line 1979 "VBNET.ATG"
+ if (canBeReDim && !canBeNormal && initializer == null) initializer = new CollectionInitializerExpression();
}
}
+
+#line 1983 "VBNET.ATG"
if (initializer == null) {
oce = new ObjectCreateExpression(type, arguments);
} else {
@@ -2025,251 +2959,371 @@ partial class Parser : AbstractParser
ace.Arguments = arguments;
oce = ace;
}
+
+ if (la.kind == 113 || la.kind == 219) {
+ if (la.kind == 219) {
- if (la.kind == 113 || la.kind == 218) {
- if (la.kind == 218) {
+#line 1998 "VBNET.ATG"
MemberInitializerExpression memberInitializer = null;
+
+ lexer.NextToken();
- Get();
+#line 2002 "VBNET.ATG"
CollectionInitializerExpression memberInitializers = new CollectionInitializerExpression();
memberInitializers.StartLocation = la.Location;
-
+
Expect(23);
- MemberInitializer(out memberInitializer);
- memberInitializers.CreateExpressions.Add(memberInitializer);
+ MemberInitializer(
+#line 2006 "VBNET.ATG"
+out memberInitializer);
+
+#line 2007 "VBNET.ATG"
+ memberInitializers.CreateExpressions.Add(memberInitializer);
while (la.kind == 12) {
- Get();
- MemberInitializer(out memberInitializer);
- memberInitializers.CreateExpressions.Add(memberInitializer);
+ lexer.NextToken();
+ MemberInitializer(
+#line 2009 "VBNET.ATG"
+out memberInitializer);
+
+#line 2010 "VBNET.ATG"
+ memberInitializers.CreateExpressions.Add(memberInitializer);
}
Expect(24);
+
+#line 2014 "VBNET.ATG"
memberInitializers.EndLocation = t.Location;
if(oce is ObjectCreateExpression)
{
((ObjectCreateExpression)oce).ObjectInitializer = memberInitializers;
}
-
+
} else {
- Get();
- CollectionInitializer(out initializer);
+ lexer.NextToken();
+ CollectionInitializer(
+#line 2024 "VBNET.ATG"
+out initializer);
+
+#line 2026 "VBNET.ATG"
if(oce is ObjectCreateExpression)
((ObjectCreateExpression)oce).ObjectInitializer = initializer;
-
+
}
}
}
- void AccessorDecls(out PropertyGetRegion getBlock, out PropertySetRegion setBlock) {
+ void AccessorDecls(
+#line 1349 "VBNET.ATG"
+out PropertyGetRegion getBlock, out PropertySetRegion setBlock) {
+
+#line 1351 "VBNET.ATG"
List attributes = new List();
AttributeSection section;
getBlock = null;
setBlock = null;
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1356 "VBNET.ATG"
+out section);
+
+#line 1356 "VBNET.ATG"
+ attributes.Add(section);
}
if (StartOf(24)) {
- GetAccessorDecl(out getBlock, attributes);
+ GetAccessorDecl(
+#line 1358 "VBNET.ATG"
+out getBlock, attributes);
if (StartOf(25)) {
- attributes = new List();
+
+#line 1360 "VBNET.ATG"
+ attributes = new List();
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1361 "VBNET.ATG"
+out section);
+
+#line 1361 "VBNET.ATG"
+ attributes.Add(section);
}
- SetAccessorDecl(out setBlock, attributes);
+ SetAccessorDecl(
+#line 1362 "VBNET.ATG"
+out setBlock, attributes);
}
} else if (StartOf(26)) {
- SetAccessorDecl(out setBlock, attributes);
+ SetAccessorDecl(
+#line 1365 "VBNET.ATG"
+out setBlock, attributes);
if (StartOf(27)) {
- attributes = new List();
+
+#line 1367 "VBNET.ATG"
+ attributes = new List();
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1368 "VBNET.ATG"
+out section);
+
+#line 1368 "VBNET.ATG"
+ attributes.Add(section);
}
- GetAccessorDecl(out getBlock, attributes);
+ GetAccessorDecl(
+#line 1369 "VBNET.ATG"
+out getBlock, attributes);
}
} else SynErr(254);
}
- void EventAccessorDeclaration(out EventAddRemoveRegion eventAccessorDeclaration) {
+ void EventAccessorDeclaration(
+#line 1312 "VBNET.ATG"
+out EventAddRemoveRegion eventAccessorDeclaration) {
+
+#line 1314 "VBNET.ATG"
Statement stmt = null;
List p = new List();
AttributeSection section;
List attributes = new List();
eventAccessorDeclaration = null;
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 1320 "VBNET.ATG"
+out section);
+
+#line 1320 "VBNET.ATG"
+ attributes.Add(section);
}
if (la.kind == 43) {
- Get();
+ lexer.NextToken();
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 1322 "VBNET.ATG"
+p);
}
Expect(26);
}
Expect(1);
- Block(out stmt);
+ Block(
+#line 1323 "VBNET.ATG"
+out stmt);
Expect(100);
Expect(43);
EndOfStmt();
+
+#line 1325 "VBNET.ATG"
eventAccessorDeclaration = new EventAddRegion(attributes);
eventAccessorDeclaration.Block = (BlockStatement)stmt;
eventAccessorDeclaration.Parameters = p;
-
- } else if (la.kind == 178) {
- Get();
+
+ } else if (la.kind == 179) {
+ lexer.NextToken();
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 1330 "VBNET.ATG"
+p);
}
Expect(26);
}
Expect(1);
- Block(out stmt);
+ Block(
+#line 1331 "VBNET.ATG"
+out stmt);
Expect(100);
- Expect(178);
+ Expect(179);
EndOfStmt();
+
+#line 1333 "VBNET.ATG"
eventAccessorDeclaration = new EventRemoveRegion(attributes);
eventAccessorDeclaration.Block = (BlockStatement)stmt;
eventAccessorDeclaration.Parameters = p;
-
- } else if (la.kind == 174) {
- Get();
+
+ } else if (la.kind == 175) {
+ lexer.NextToken();
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 1338 "VBNET.ATG"
+p);
}
Expect(26);
}
Expect(1);
- Block(out stmt);
+ Block(
+#line 1339 "VBNET.ATG"
+out stmt);
Expect(100);
- Expect(174);
+ Expect(175);
EndOfStmt();
+
+#line 1341 "VBNET.ATG"
eventAccessorDeclaration = new EventRaiseRegion(attributes);
eventAccessorDeclaration.Block = (BlockStatement)stmt;
eventAccessorDeclaration.Parameters = p;
-
+
} else SynErr(255);
}
- void OverloadableOperator(out OverloadableOperatorType operatorType) {
- operatorType = OverloadableOperatorType.None;
+ void OverloadableOperator(
+#line 1254 "VBNET.ATG"
+out OverloadableOperatorType operatorType) {
+
+#line 1255 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.None;
switch (la.kind) {
case 19: {
- Get();
- operatorType = OverloadableOperatorType.Add;
+ lexer.NextToken();
+
+#line 1257 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Add;
break;
}
case 18: {
- Get();
- operatorType = OverloadableOperatorType.Subtract;
+ lexer.NextToken();
+
+#line 1259 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Subtract;
break;
}
case 22: {
- Get();
- operatorType = OverloadableOperatorType.Multiply;
+ lexer.NextToken();
+
+#line 1261 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Multiply;
break;
}
case 14: {
- Get();
- operatorType = OverloadableOperatorType.Divide;
+ lexer.NextToken();
+
+#line 1263 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Divide;
break;
}
case 15: {
- Get();
- operatorType = OverloadableOperatorType.DivideInteger;
+ lexer.NextToken();
+
+#line 1265 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.DivideInteger;
break;
}
case 13: {
- Get();
- operatorType = OverloadableOperatorType.Concat;
+ lexer.NextToken();
+
+#line 1267 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Concat;
break;
}
- case 136: {
- Get();
- operatorType = OverloadableOperatorType.Like;
+ case 137: {
+ lexer.NextToken();
+
+#line 1269 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Like;
break;
}
- case 140: {
- Get();
- operatorType = OverloadableOperatorType.Modulus;
+ case 141: {
+ lexer.NextToken();
+
+#line 1271 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Modulus;
break;
}
case 47: {
- Get();
- operatorType = OverloadableOperatorType.BitwiseAnd;
+ lexer.NextToken();
+
+#line 1273 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.BitwiseAnd;
break;
}
- case 161: {
- Get();
- operatorType = OverloadableOperatorType.BitwiseOr;
+ case 162: {
+ lexer.NextToken();
+
+#line 1275 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.BitwiseOr;
break;
}
- case 221: {
- Get();
- operatorType = OverloadableOperatorType.ExclusiveOr;
+ case 222: {
+ lexer.NextToken();
+
+#line 1277 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.ExclusiveOr;
break;
}
case 20: {
- Get();
- operatorType = OverloadableOperatorType.Power;
+ lexer.NextToken();
+
+#line 1279 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Power;
break;
}
case 32: {
- Get();
- operatorType = OverloadableOperatorType.ShiftLeft;
+ lexer.NextToken();
+
+#line 1281 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.ShiftLeft;
break;
}
case 33: {
- Get();
- operatorType = OverloadableOperatorType.ShiftRight;
+ lexer.NextToken();
+
+#line 1283 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.ShiftRight;
break;
}
case 10: {
- Get();
- operatorType = OverloadableOperatorType.Equality;
+ lexer.NextToken();
+
+#line 1285 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.Equality;
break;
}
case 29: {
- Get();
- operatorType = OverloadableOperatorType.InEquality;
+ lexer.NextToken();
+
+#line 1287 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.InEquality;
break;
}
case 28: {
- Get();
- operatorType = OverloadableOperatorType.LessThan;
+ lexer.NextToken();
+
+#line 1289 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.LessThan;
break;
}
case 31: {
- Get();
- operatorType = OverloadableOperatorType.LessThanOrEqual;
+ lexer.NextToken();
+
+#line 1291 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.LessThanOrEqual;
break;
}
case 27: {
- Get();
- operatorType = OverloadableOperatorType.GreaterThan;
+ lexer.NextToken();
+
+#line 1293 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.GreaterThan;
break;
}
case 30: {
- Get();
- operatorType = OverloadableOperatorType.GreaterThanOrEqual;
+ lexer.NextToken();
+
+#line 1295 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.GreaterThanOrEqual;
break;
}
case 81: {
- Get();
- operatorType = OverloadableOperatorType.CType;
+ lexer.NextToken();
+
+#line 1297 "VBNET.ATG"
+ operatorType = OverloadableOperatorType.CType;
break;
}
- case 2: case 45: case 49: case 51: case 52: case 53: case 54: case 57: case 74: case 85: case 91: case 94: case 103: case 108: case 113: case 120: case 126: case 130: case 133: case 156: case 162: case 169: case 188: case 197: case 198: case 208: case 209: case 215: {
+ case 2: case 45: case 49: case 51: case 52: case 53: case 54: case 57: case 74: case 85: case 91: case 94: case 103: case 108: case 113: case 120: case 126: case 130: case 133: case 157: case 163: case 170: case 189: case 198: case 199: case 209: case 210: case 216: {
Identifier();
+
+#line 1301 "VBNET.ATG"
string opName = t.val;
if (string.Equals(opName, "istrue", StringComparison.InvariantCultureIgnoreCase)) {
operatorType = OverloadableOperatorType.IsTrue;
@@ -2278,697 +3332,1105 @@ partial class Parser : AbstractParser
} else {
Error("Invalid operator. Possible operators are '+', '-', 'Not', 'IsTrue', 'IsFalse'.");
}
-
+
break;
}
default: SynErr(256); break;
}
}
- void GetAccessorDecl(out PropertyGetRegion getBlock, List attributes) {
- Statement stmt = null; Modifiers m;
- PropertyAccessorAccessModifier(out m);
+ void GetAccessorDecl(
+#line 1375 "VBNET.ATG"
+out PropertyGetRegion getBlock, List attributes) {
+
+#line 1376 "VBNET.ATG"
+ Statement stmt = null; Modifiers m;
+ PropertyAccessorAccessModifier(
+#line 1378 "VBNET.ATG"
+out m);
Expect(115);
- Location startLocation = t.Location;
+
+#line 1380 "VBNET.ATG"
+ Location startLocation = t.Location;
Expect(1);
- Block(out stmt);
- getBlock = new PropertyGetRegion((BlockStatement)stmt, attributes);
+ Block(
+#line 1382 "VBNET.ATG"
+out stmt);
+
+#line 1383 "VBNET.ATG"
+ getBlock = new PropertyGetRegion((BlockStatement)stmt, attributes);
Expect(100);
Expect(115);
- getBlock.Modifier = m;
- getBlock.StartLocation = startLocation; getBlock.EndLocation = t.EndLocation;
+
+#line 1385 "VBNET.ATG"
+ getBlock.Modifier = m;
+
+#line 1386 "VBNET.ATG"
+ getBlock.StartLocation = startLocation; getBlock.EndLocation = t.EndLocation;
EndOfStmt();
}
- void SetAccessorDecl(out PropertySetRegion setBlock, List attributes) {
+ void SetAccessorDecl(
+#line 1391 "VBNET.ATG"
+out PropertySetRegion setBlock, List attributes) {
+
+#line 1393 "VBNET.ATG"
Statement stmt = null;
List p = new List();
Modifiers m;
-
- PropertyAccessorAccessModifier(out m);
- Expect(183);
- Location startLocation = t.Location;
+
+ PropertyAccessorAccessModifier(
+#line 1398 "VBNET.ATG"
+out m);
+ Expect(184);
+
+#line 1400 "VBNET.ATG"
+ Location startLocation = t.Location;
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(p);
+ FormalParameterList(
+#line 1401 "VBNET.ATG"
+p);
}
Expect(26);
}
Expect(1);
- Block(out stmt);
+ Block(
+#line 1403 "VBNET.ATG"
+out stmt);
+
+#line 1405 "VBNET.ATG"
setBlock = new PropertySetRegion((BlockStatement)stmt, attributes);
setBlock.Modifier = m;
setBlock.Parameters = p;
-
+
Expect(100);
- Expect(183);
- setBlock.StartLocation = startLocation; setBlock.EndLocation = t.EndLocation;
+ Expect(184);
+
+#line 1410 "VBNET.ATG"
+ setBlock.StartLocation = startLocation; setBlock.EndLocation = t.EndLocation;
EndOfStmt();
}
- void PropertyAccessorAccessModifier(out Modifiers m) {
- m = Modifiers.None;
+ void PropertyAccessorAccessModifier(
+#line 3450 "VBNET.ATG"
+out Modifiers m) {
+
+#line 3451 "VBNET.ATG"
+ m = Modifiers.None;
while (StartOf(28)) {
- if (la.kind == 173) {
- Get();
- m |= Modifiers.Public;
- } else if (la.kind == 172) {
- Get();
- m |= Modifiers.Protected;
+ if (la.kind == 174) {
+ lexer.NextToken();
+
+#line 3453 "VBNET.ATG"
+ m |= Modifiers.Public;
+ } else if (la.kind == 173) {
+ lexer.NextToken();
+
+#line 3454 "VBNET.ATG"
+ m |= Modifiers.Protected;
} else if (la.kind == 112) {
- Get();
- m |= Modifiers.Internal;
+ lexer.NextToken();
+
+#line 3455 "VBNET.ATG"
+ m |= Modifiers.Internal;
} else {
- Get();
- m |= Modifiers.Private;
+ lexer.NextToken();
+
+#line 3456 "VBNET.ATG"
+ m |= Modifiers.Private;
}
}
}
- void ArrayInitializationModifier(out List arrayModifiers) {
- arrayModifiers = null;
+ void ArrayInitializationModifier(
+#line 1508 "VBNET.ATG"
+out List arrayModifiers) {
+#line 1510 "VBNET.ATG"
+ arrayModifiers = null;
+
Expect(25);
- InitializationRankList(out arrayModifiers);
+ InitializationRankList(
+#line 1512 "VBNET.ATG"
+out arrayModifiers);
Expect(26);
}
- void ArrayNameModifier(out ArrayList arrayModifiers) {
- arrayModifiers = null;
+ void ArrayNameModifier(
+#line 2527 "VBNET.ATG"
+out ArrayList arrayModifiers) {
- ArrayTypeModifiers(out arrayModifiers);
+#line 2529 "VBNET.ATG"
+ arrayModifiers = null;
+
+ ArrayTypeModifiers(
+#line 2531 "VBNET.ATG"
+out arrayModifiers);
}
- void InitializationRankList(out List rank) {
+ void InitializationRankList(
+#line 1516 "VBNET.ATG"
+out List rank) {
+
+#line 1518 "VBNET.ATG"
rank = new List();
Expression expr = null;
-
- Expr(out expr);
- if (la.kind == 201) {
- Get();
- EnsureIsZero(expr);
- Expr(out expr);
- }
- if (expr != null) { rank.Add(expr); }
+
+ Expr(
+#line 1521 "VBNET.ATG"
+out expr);
+ if (la.kind == 202) {
+ lexer.NextToken();
+
+#line 1522 "VBNET.ATG"
+ EnsureIsZero(expr);
+ Expr(
+#line 1523 "VBNET.ATG"
+out expr);
+ }
+
+#line 1525 "VBNET.ATG"
+ if (expr != null) { rank.Add(expr); }
while (la.kind == 12) {
- Get();
- Expr(out expr);
- if (la.kind == 201) {
- Get();
- EnsureIsZero(expr);
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 1527 "VBNET.ATG"
+out expr);
+ if (la.kind == 202) {
+ lexer.NextToken();
+
+#line 1528 "VBNET.ATG"
+ EnsureIsZero(expr);
+ Expr(
+#line 1529 "VBNET.ATG"
+out expr);
}
- if (expr != null) { rank.Add(expr); }
+
+#line 1531 "VBNET.ATG"
+ if (expr != null) { rank.Add(expr); }
}
}
- void CollectionInitializer(out CollectionInitializerExpression outExpr) {
+ void CollectionInitializer(
+#line 1536 "VBNET.ATG"
+out CollectionInitializerExpression outExpr) {
+
+#line 1538 "VBNET.ATG"
Expression expr = null;
CollectionInitializerExpression initializer = new CollectionInitializerExpression();
-
+
Expect(23);
if (StartOf(29)) {
- Expr(out expr);
- if (expr != null) { initializer.CreateExpressions.Add(expr); }
+ Expr(
+#line 1543 "VBNET.ATG"
+out expr);
- while (NotFinalComma()) {
+#line 1545 "VBNET.ATG"
+ if (expr != null) { initializer.CreateExpressions.Add(expr); }
+
+ while (
+#line 1548 "VBNET.ATG"
+NotFinalComma()) {
Expect(12);
- Expr(out expr);
- if (expr != null) { initializer.CreateExpressions.Add(expr); }
+ Expr(
+#line 1548 "VBNET.ATG"
+out expr);
+
+#line 1549 "VBNET.ATG"
+ if (expr != null) { initializer.CreateExpressions.Add(expr); }
}
}
Expect(24);
- outExpr = initializer;
+
+#line 1552 "VBNET.ATG"
+ outExpr = initializer;
}
- void EventMemberSpecifier(out string name) {
- string eventName;
+ void EventMemberSpecifier(
+#line 1622 "VBNET.ATG"
+out string name) {
+
+#line 1623 "VBNET.ATG"
+ string eventName;
if (StartOf(4)) {
Identifier();
- } else if (la.kind == 144) {
- Get();
- } else if (la.kind == 139) {
- Get();
+ } else if (la.kind == 145) {
+ lexer.NextToken();
+ } else if (la.kind == 140) {
+ lexer.NextToken();
} else SynErr(257);
- name = t.val;
+
+#line 1626 "VBNET.ATG"
+ name = t.val;
Expect(16);
- IdentifierOrKeyword(out eventName);
- name = name + "." + eventName;
+ IdentifierOrKeyword(
+#line 1628 "VBNET.ATG"
+out eventName);
+
+#line 1629 "VBNET.ATG"
+ name = name + "." + eventName;
}
- void IdentifierOrKeyword(out string name) {
- Get();
- name = t.val;
+ void IdentifierOrKeyword(
+#line 3383 "VBNET.ATG"
+out string name) {
+ lexer.NextToken();
+
+#line 3385 "VBNET.ATG"
+ name = t.val;
}
- void QueryExpr(out Expression expr) {
+ void QueryExpr(
+#line 2051 "VBNET.ATG"
+out Expression expr) {
+
+#line 2053 "VBNET.ATG"
QueryExpressionVB qexpr = new QueryExpressionVB();
qexpr.StartLocation = la.Location;
expr = qexpr;
-
- FromOrAggregateQueryOperator(qexpr.Clauses);
+
+ FromOrAggregateQueryOperator(
+#line 2057 "VBNET.ATG"
+qexpr.Clauses);
while (StartOf(30)) {
- QueryOperator(qexpr.Clauses);
+ QueryOperator(
+#line 2058 "VBNET.ATG"
+qexpr.Clauses);
}
- qexpr.EndLocation = t.EndLocation;
+#line 2060 "VBNET.ATG"
+ qexpr.EndLocation = t.EndLocation;
+
}
- void LambdaExpr(out Expression expr) {
+ void LambdaExpr(
+#line 2033 "VBNET.ATG"
+out Expression expr) {
+
+#line 2035 "VBNET.ATG"
Expression inner = null;
LambdaExpression lambda = new LambdaExpression();
lambda.StartLocation = la.Location;
-
+
Expect(114);
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(6)) {
- FormalParameterList(lambda.Parameters);
+ FormalParameterList(
+#line 2041 "VBNET.ATG"
+lambda.Parameters);
}
Expect(26);
}
- Expr(out inner);
+ Expr(
+#line 2042 "VBNET.ATG"
+out inner);
+
+#line 2044 "VBNET.ATG"
lambda.ExpressionBody = inner;
lambda.EndLocation = t.EndLocation; // la.Location?
-
+
expr = lambda;
-
+
}
- void DisjunctionExpr(out Expression outExpr) {
+ void DisjunctionExpr(
+#line 1806 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1808 "VBNET.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- ConjunctionExpr(out outExpr);
- while (la.kind == 161 || la.kind == 163 || la.kind == 221) {
- if (la.kind == 161) {
- Get();
- op = BinaryOperatorType.BitwiseOr;
- } else if (la.kind == 163) {
- Get();
- op = BinaryOperatorType.LogicalOr;
+
+ ConjunctionExpr(
+#line 1811 "VBNET.ATG"
+out outExpr);
+ while (la.kind == 162 || la.kind == 164 || la.kind == 222) {
+ if (la.kind == 162) {
+ lexer.NextToken();
+
+#line 1814 "VBNET.ATG"
+ op = BinaryOperatorType.BitwiseOr;
+ } else if (la.kind == 164) {
+ lexer.NextToken();
+
+#line 1815 "VBNET.ATG"
+ op = BinaryOperatorType.LogicalOr;
} else {
- Get();
- op = BinaryOperatorType.ExclusiveOr;
+ lexer.NextToken();
+
+#line 1816 "VBNET.ATG"
+ op = BinaryOperatorType.ExclusiveOr;
}
- ConjunctionExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ ConjunctionExpr(
+#line 1818 "VBNET.ATG"
+out expr);
+
+#line 1818 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void AssignmentOperator(out AssignmentOperatorType op) {
- op = AssignmentOperatorType.None;
+ void AssignmentOperator(
+#line 1640 "VBNET.ATG"
+out AssignmentOperatorType op) {
+
+#line 1641 "VBNET.ATG"
+ op = AssignmentOperatorType.None;
switch (la.kind) {
case 10: {
- Get();
- op = AssignmentOperatorType.Assign;
+ lexer.NextToken();
+
+#line 1642 "VBNET.ATG"
+ op = AssignmentOperatorType.Assign;
break;
}
case 42: {
- Get();
- op = AssignmentOperatorType.ConcatString;
+ lexer.NextToken();
+
+#line 1643 "VBNET.ATG"
+ op = AssignmentOperatorType.ConcatString;
break;
}
case 34: {
- Get();
- op = AssignmentOperatorType.Add;
+ lexer.NextToken();
+
+#line 1644 "VBNET.ATG"
+ op = AssignmentOperatorType.Add;
break;
}
case 36: {
- Get();
- op = AssignmentOperatorType.Subtract;
+ lexer.NextToken();
+
+#line 1645 "VBNET.ATG"
+ op = AssignmentOperatorType.Subtract;
break;
}
case 37: {
- Get();
- op = AssignmentOperatorType.Multiply;
+ lexer.NextToken();
+
+#line 1646 "VBNET.ATG"
+ op = AssignmentOperatorType.Multiply;
break;
}
case 38: {
- Get();
- op = AssignmentOperatorType.Divide;
+ lexer.NextToken();
+
+#line 1647 "VBNET.ATG"
+ op = AssignmentOperatorType.Divide;
break;
}
case 39: {
- Get();
- op = AssignmentOperatorType.DivideInteger;
+ lexer.NextToken();
+
+#line 1648 "VBNET.ATG"
+ op = AssignmentOperatorType.DivideInteger;
break;
}
case 35: {
- Get();
- op = AssignmentOperatorType.Power;
+ lexer.NextToken();
+
+#line 1649 "VBNET.ATG"
+ op = AssignmentOperatorType.Power;
break;
}
case 40: {
- Get();
- op = AssignmentOperatorType.ShiftLeft;
+ lexer.NextToken();
+
+#line 1650 "VBNET.ATG"
+ op = AssignmentOperatorType.ShiftLeft;
break;
}
case 41: {
- Get();
- op = AssignmentOperatorType.ShiftRight;
+ lexer.NextToken();
+
+#line 1651 "VBNET.ATG"
+ op = AssignmentOperatorType.ShiftRight;
break;
}
default: SynErr(258); break;
}
}
- void SimpleExpr(out Expression pexpr) {
- string name;
- SimpleNonInvocationExpression(out pexpr);
+ void SimpleExpr(
+#line 1655 "VBNET.ATG"
+out Expression pexpr) {
+
+#line 1656 "VBNET.ATG"
+ string name;
+ SimpleNonInvocationExpression(
+#line 1658 "VBNET.ATG"
+out pexpr);
while (la.kind == 16 || la.kind == 17 || la.kind == 25) {
if (la.kind == 16) {
- Get();
- IdentifierOrKeyword(out name);
- pexpr = new MemberReferenceExpression(pexpr, name);
- if (la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
- Expect(25);
- Expect(155);
- TypeArgumentList(((MemberReferenceExpression)pexpr).TypeArguments);
+ lexer.NextToken();
+ IdentifierOrKeyword(
+#line 1660 "VBNET.ATG"
+out name);
+
+#line 1661 "VBNET.ATG"
+ pexpr = new MemberReferenceExpression(pexpr, name);
+ if (
+#line 1662 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
+ lexer.NextToken();
+ Expect(156);
+ TypeArgumentList(
+#line 1663 "VBNET.ATG"
+((MemberReferenceExpression)pexpr).TypeArguments);
Expect(26);
}
} else if (la.kind == 17) {
- Get();
- IdentifierOrKeyword(out name);
- pexpr = new BinaryOperatorExpression(pexpr, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name));
+ lexer.NextToken();
+ IdentifierOrKeyword(
+#line 1665 "VBNET.ATG"
+out name);
+
+#line 1665 "VBNET.ATG"
+ pexpr = new BinaryOperatorExpression(pexpr, BinaryOperatorType.DictionaryAccess, new PrimitiveExpression(name, name));
} else {
- InvocationExpression(ref pexpr);
+ InvocationExpression(
+#line 1666 "VBNET.ATG"
+ref pexpr);
}
}
}
- void SimpleNonInvocationExpression(out Expression pexpr) {
+ void SimpleNonInvocationExpression(
+#line 1670 "VBNET.ATG"
+out Expression pexpr) {
+
+#line 1672 "VBNET.ATG"
Expression expr;
CollectionInitializerExpression cie;
TypeReference type = null;
string name = String.Empty;
pexpr = null;
-
+
if (StartOf(31)) {
switch (la.kind) {
case 3: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1681 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
case 4: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1682 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
case 7: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1683 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
case 6: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1684 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
case 5: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1685 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
case 9: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1686 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
case 8: {
- Get();
- pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
+ lexer.NextToken();
+
+#line 1687 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(t.literalValue, t.val) { LiteralFormat = t.literalFormat };
break;
}
- case 202: {
- Get();
- pexpr = new PrimitiveExpression(true, "true");
+ case 203: {
+ lexer.NextToken();
+
+#line 1689 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(true, "true");
break;
}
case 109: {
- Get();
- pexpr = new PrimitiveExpression(false, "false");
+ lexer.NextToken();
+
+#line 1690 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(false, "false");
break;
}
- case 151: {
- Get();
- pexpr = new PrimitiveExpression(null, "null");
+ case 152: {
+ lexer.NextToken();
+
+#line 1691 "VBNET.ATG"
+ pexpr = new PrimitiveExpression(null, "null");
break;
}
case 25: {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 1692 "VBNET.ATG"
+out expr);
Expect(26);
- pexpr = new ParenthesizedExpression(expr);
+
+#line 1692 "VBNET.ATG"
+ pexpr = new ParenthesizedExpression(expr);
break;
}
- case 2: case 45: case 49: case 51: case 52: case 53: case 54: case 57: case 74: case 85: case 91: case 94: case 103: case 108: case 113: case 120: case 126: case 130: case 133: case 156: case 162: case 169: case 188: case 197: case 198: case 208: case 209: case 215: {
+ case 2: case 45: case 49: case 51: case 52: case 53: case 54: case 57: case 74: case 85: case 91: case 94: case 103: case 108: case 113: case 120: case 126: case 130: case 133: case 157: case 163: case 170: case 189: case 198: case 199: case 209: case 210: case 216: {
Identifier();
+
+#line 1694 "VBNET.ATG"
pexpr = new IdentifierExpression(t.val);
pexpr.StartLocation = t.Location; pexpr.EndLocation = t.EndLocation;
-
- if (la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
- Expect(25);
- Expect(155);
- TypeArgumentList(((IdentifierExpression)pexpr).TypeArguments);
+
+ if (
+#line 1697 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
+ lexer.NextToken();
+ Expect(156);
+ TypeArgumentList(
+#line 1698 "VBNET.ATG"
+((IdentifierExpression)pexpr).TypeArguments);
Expect(26);
}
break;
}
- case 55: case 58: case 69: case 86: case 87: case 96: case 128: case 137: case 154: case 181: case 186: case 187: case 193: case 206: case 207: case 210: {
- string val = String.Empty;
+ case 55: case 58: case 69: case 86: case 87: case 96: case 128: case 138: case 155: case 182: case 187: case 188: case 194: case 207: case 208: case 211: {
+
+#line 1700 "VBNET.ATG"
+ string val = String.Empty;
if (StartOf(12)) {
- PrimitiveTypeName(out val);
- } else {
- Get();
- val = "System.Object";
- }
- pexpr = new TypeReferenceExpression(new TypeReference(val, true));
+ PrimitiveTypeName(
+#line 1701 "VBNET.ATG"
+out val);
+ } else if (la.kind == 155) {
+ lexer.NextToken();
+
+#line 1701 "VBNET.ATG"
+ val = "System.Object";
+ } else SynErr(259);
+
+#line 1702 "VBNET.ATG"
+ pexpr = new TypeReferenceExpression(new TypeReference(val, true));
break;
}
- case 139: {
- Get();
- pexpr = new ThisReferenceExpression();
+ case 140: {
+ lexer.NextToken();
+
+#line 1703 "VBNET.ATG"
+ pexpr = new ThisReferenceExpression();
break;
}
- case 144: case 145: {
- Expression retExpr = null;
- if (la.kind == 144) {
- Get();
- retExpr = new BaseReferenceExpression();
- } else {
- Get();
- retExpr = new ClassReferenceExpression();
- }
+ case 145: case 146: {
+
+#line 1704 "VBNET.ATG"
+ Expression retExpr = null;
+ if (la.kind == 145) {
+ lexer.NextToken();
+
+#line 1705 "VBNET.ATG"
+ retExpr = new BaseReferenceExpression();
+ } else if (la.kind == 146) {
+ lexer.NextToken();
+
+#line 1706 "VBNET.ATG"
+ retExpr = new ClassReferenceExpression();
+ } else SynErr(260);
Expect(16);
- IdentifierOrKeyword(out name);
- pexpr = new MemberReferenceExpression(retExpr, name);
+ IdentifierOrKeyword(
+#line 1708 "VBNET.ATG"
+out name);
+
+#line 1708 "VBNET.ATG"
+ pexpr = new MemberReferenceExpression(retExpr, name);
break;
}
case 117: {
- Get();
+ lexer.NextToken();
Expect(16);
Identifier();
- type = new TypeReference(t.val ?? "");
- type.IsGlobal = true;
- pexpr = new TypeReferenceExpression(type);
+
+#line 1710 "VBNET.ATG"
+ type = new TypeReference(t.val ?? "");
+
+#line 1712 "VBNET.ATG"
+ type.IsGlobal = true;
+
+#line 1713 "VBNET.ATG"
+ pexpr = new TypeReferenceExpression(type);
break;
}
- case 148: {
- ObjectCreateExpression(out expr);
- pexpr = expr;
+ case 149: {
+ ObjectCreateExpression(
+#line 1714 "VBNET.ATG"
+out expr);
+
+#line 1714 "VBNET.ATG"
+ pexpr = expr;
break;
}
case 23: {
- CollectionInitializer(out cie);
- pexpr = cie;
+ CollectionInitializer(
+#line 1715 "VBNET.ATG"
+out cie);
+
+#line 1715 "VBNET.ATG"
+ pexpr = cie;
break;
}
- case 81: case 93: case 204: {
- CastType castType = CastType.Cast;
+ case 81: case 93: case 205: {
+
+#line 1717 "VBNET.ATG"
+ CastType castType = CastType.Cast;
if (la.kind == 93) {
- Get();
+ lexer.NextToken();
} else if (la.kind == 81) {
- Get();
- castType = CastType.Conversion;
- } else {
- Get();
- castType = CastType.TryCast;
- }
+ lexer.NextToken();
+
+#line 1719 "VBNET.ATG"
+ castType = CastType.Conversion;
+ } else if (la.kind == 205) {
+ lexer.NextToken();
+
+#line 1720 "VBNET.ATG"
+ castType = CastType.TryCast;
+ } else SynErr(261);
Expect(25);
- Expr(out expr);
+ Expr(
+#line 1722 "VBNET.ATG"
+out expr);
Expect(12);
- TypeName(out type);
+ TypeName(
+#line 1722 "VBNET.ATG"
+out type);
Expect(26);
- pexpr = new CastExpression(type, expr, castType);
+
+#line 1723 "VBNET.ATG"
+ pexpr = new CastExpression(type, expr, castType);
break;
}
case 63: case 64: case 65: case 66: case 67: case 68: case 70: case 72: case 73: case 77: case 78: case 79: case 80: case 82: case 83: case 84: {
- CastTarget(out type);
+ CastTarget(
+#line 1724 "VBNET.ATG"
+out type);
Expect(25);
- Expr(out expr);
+ Expr(
+#line 1724 "VBNET.ATG"
+out expr);
Expect(26);
- pexpr = new CastExpression(type, expr, CastType.PrimitiveConversion);
+
+#line 1724 "VBNET.ATG"
+ pexpr = new CastExpression(type, expr, CastType.PrimitiveConversion);
break;
}
case 44: {
- Get();
- Expr(out expr);
- pexpr = new AddressOfExpression(expr);
+ lexer.NextToken();
+ Expr(
+#line 1725 "VBNET.ATG"
+out expr);
+
+#line 1725 "VBNET.ATG"
+ pexpr = new AddressOfExpression(expr);
break;
}
case 116: {
- Get();
+ lexer.NextToken();
Expect(25);
- GetTypeTypeName(out type);
+ GetTypeTypeName(
+#line 1726 "VBNET.ATG"
+out type);
Expect(26);
- pexpr = new TypeOfExpression(type);
+
+#line 1726 "VBNET.ATG"
+ pexpr = new TypeOfExpression(type);
break;
}
- case 205: {
- Get();
- SimpleExpr(out expr);
+ case 206: {
+ lexer.NextToken();
+ SimpleExpr(
+#line 1727 "VBNET.ATG"
+out expr);
Expect(131);
- TypeName(out type);
- pexpr = new TypeOfIsExpression(expr, type);
+ TypeName(
+#line 1727 "VBNET.ATG"
+out type);
+
+#line 1727 "VBNET.ATG"
+ pexpr = new TypeOfIsExpression(expr, type);
break;
}
case 122: {
- ConditionalExpression(out pexpr);
+ ConditionalExpression(
+#line 1728 "VBNET.ATG"
+out pexpr);
break;
}
}
} else if (la.kind == 16) {
- Get();
- IdentifierOrKeyword(out name);
+ lexer.NextToken();
+ IdentifierOrKeyword(
+#line 1732 "VBNET.ATG"
+out name);
+
+#line 1732 "VBNET.ATG"
pexpr = new MemberReferenceExpression(null, name);
- } else SynErr(259);
+ } else SynErr(262);
}
- void TypeArgumentList(List typeArguments) {
+ void TypeArgumentList(
+#line 2563 "VBNET.ATG"
+List typeArguments) {
+
+#line 2565 "VBNET.ATG"
TypeReference typeref;
+
+ TypeName(
+#line 2567 "VBNET.ATG"
+out typeref);
- TypeName(out typeref);
- if (typeref != null) typeArguments.Add(typeref);
+#line 2567 "VBNET.ATG"
+ if (typeref != null) typeArguments.Add(typeref);
while (la.kind == 12) {
- Get();
- TypeName(out typeref);
- if (typeref != null) typeArguments.Add(typeref);
+ lexer.NextToken();
+ TypeName(
+#line 2570 "VBNET.ATG"
+out typeref);
+
+#line 2570 "VBNET.ATG"
+ if (typeref != null) typeArguments.Add(typeref);
}
}
- void InvocationExpression(ref Expression pexpr) {
- List parameters = null;
+ void InvocationExpression(
+#line 1770 "VBNET.ATG"
+ref Expression pexpr) {
+
+#line 1771 "VBNET.ATG"
+ List parameters = null;
Expect(25);
- Location start = t.Location;
- ArgumentList(out parameters);
+
+#line 1773 "VBNET.ATG"
+ Location start = t.Location;
+ ArgumentList(
+#line 1774 "VBNET.ATG"
+out parameters);
Expect(26);
+
+#line 1777 "VBNET.ATG"
pexpr = new InvocationExpression(pexpr, parameters);
+
- pexpr.StartLocation = start; pexpr.EndLocation = t.Location;
+#line 1779 "VBNET.ATG"
+ pexpr.StartLocation = start; pexpr.EndLocation = t.Location;
}
- void PrimitiveTypeName(out string type) {
- type = String.Empty;
+ void PrimitiveTypeName(
+#line 3390 "VBNET.ATG"
+out string type) {
+
+#line 3391 "VBNET.ATG"
+ type = String.Empty;
switch (la.kind) {
case 55: {
- Get();
- type = "System.Boolean";
+ lexer.NextToken();
+
+#line 3392 "VBNET.ATG"
+ type = "System.Boolean";
break;
}
case 86: {
- Get();
- type = "System.DateTime";
+ lexer.NextToken();
+
+#line 3393 "VBNET.ATG"
+ type = "System.DateTime";
break;
}
case 69: {
- Get();
- type = "System.Char";
+ lexer.NextToken();
+
+#line 3394 "VBNET.ATG"
+ type = "System.Char";
break;
}
- case 193: {
- Get();
- type = "System.String";
+ case 194: {
+ lexer.NextToken();
+
+#line 3395 "VBNET.ATG"
+ type = "System.String";
break;
}
case 87: {
- Get();
- type = "System.Decimal";
+ lexer.NextToken();
+
+#line 3396 "VBNET.ATG"
+ type = "System.Decimal";
break;
}
case 58: {
- Get();
- type = "System.Byte";
+ lexer.NextToken();
+
+#line 3397 "VBNET.ATG"
+ type = "System.Byte";
break;
}
- case 186: {
- Get();
- type = "System.Int16";
+ case 187: {
+ lexer.NextToken();
+
+#line 3398 "VBNET.ATG"
+ type = "System.Int16";
break;
}
case 128: {
- Get();
- type = "System.Int32";
+ lexer.NextToken();
+
+#line 3399 "VBNET.ATG"
+ type = "System.Int32";
break;
}
- case 137: {
- Get();
- type = "System.Int64";
+ case 138: {
+ lexer.NextToken();
+
+#line 3400 "VBNET.ATG"
+ type = "System.Int64";
break;
}
- case 187: {
- Get();
- type = "System.Single";
+ case 188: {
+ lexer.NextToken();
+
+#line 3401 "VBNET.ATG"
+ type = "System.Single";
break;
}
case 96: {
- Get();
- type = "System.Double";
+ lexer.NextToken();
+
+#line 3402 "VBNET.ATG"
+ type = "System.Double";
break;
}
- case 206: {
- Get();
- type = "System.UInt32";
+ case 207: {
+ lexer.NextToken();
+
+#line 3403 "VBNET.ATG"
+ type = "System.UInt32";
break;
}
- case 207: {
- Get();
- type = "System.UInt64";
+ case 208: {
+ lexer.NextToken();
+
+#line 3404 "VBNET.ATG"
+ type = "System.UInt64";
break;
}
- case 210: {
- Get();
- type = "System.UInt16";
+ case 211: {
+ lexer.NextToken();
+
+#line 3405 "VBNET.ATG"
+ type = "System.UInt16";
break;
}
- case 181: {
- Get();
- type = "System.SByte";
+ case 182: {
+ lexer.NextToken();
+
+#line 3406 "VBNET.ATG"
+ type = "System.SByte";
break;
}
- default: SynErr(260); break;
+ default: SynErr(263); break;
}
}
- void CastTarget(out TypeReference type) {
- type = null;
+ void CastTarget(
+#line 1784 "VBNET.ATG"
+out TypeReference type) {
+#line 1786 "VBNET.ATG"
+ type = null;
+
switch (la.kind) {
case 63: {
- Get();
- type = new TypeReference("System.Boolean", true);
+ lexer.NextToken();
+
+#line 1788 "VBNET.ATG"
+ type = new TypeReference("System.Boolean", true);
break;
}
case 64: {
- Get();
- type = new TypeReference("System.Byte", true);
+ lexer.NextToken();
+
+#line 1789 "VBNET.ATG"
+ type = new TypeReference("System.Byte", true);
break;
}
case 77: {
- Get();
- type = new TypeReference("System.SByte", true);
+ lexer.NextToken();
+
+#line 1790 "VBNET.ATG"
+ type = new TypeReference("System.SByte", true);
break;
}
case 65: {
- Get();
- type = new TypeReference("System.Char", true);
+ lexer.NextToken();
+
+#line 1791 "VBNET.ATG"
+ type = new TypeReference("System.Char", true);
break;
}
case 66: {
- Get();
- type = new TypeReference("System.DateTime", true);
+ lexer.NextToken();
+
+#line 1792 "VBNET.ATG"
+ type = new TypeReference("System.DateTime", true);
break;
}
case 68: {
- Get();
- type = new TypeReference("System.Decimal", true);
+ lexer.NextToken();
+
+#line 1793 "VBNET.ATG"
+ type = new TypeReference("System.Decimal", true);
break;
}
case 67: {
- Get();
- type = new TypeReference("System.Double", true);
+ lexer.NextToken();
+
+#line 1794 "VBNET.ATG"
+ type = new TypeReference("System.Double", true);
break;
}
case 78: {
- Get();
- type = new TypeReference("System.Int16", true);
+ lexer.NextToken();
+
+#line 1795 "VBNET.ATG"
+ type = new TypeReference("System.Int16", true);
break;
}
case 70: {
- Get();
- type = new TypeReference("System.Int32", true);
+ lexer.NextToken();
+
+#line 1796 "VBNET.ATG"
+ type = new TypeReference("System.Int32", true);
break;
}
case 72: {
- Get();
- type = new TypeReference("System.Int64", true);
+ lexer.NextToken();
+
+#line 1797 "VBNET.ATG"
+ type = new TypeReference("System.Int64", true);
break;
}
case 84: {
- Get();
- type = new TypeReference("System.UInt16", true);
+ lexer.NextToken();
+
+#line 1798 "VBNET.ATG"
+ type = new TypeReference("System.UInt16", true);
break;
}
case 82: {
- Get();
- type = new TypeReference("System.UInt32", true);
+ lexer.NextToken();
+
+#line 1799 "VBNET.ATG"
+ type = new TypeReference("System.UInt32", true);
break;
}
case 83: {
- Get();
- type = new TypeReference("System.UInt64", true);
+ lexer.NextToken();
+
+#line 1800 "VBNET.ATG"
+ type = new TypeReference("System.UInt64", true);
break;
}
case 73: {
- Get();
- type = new TypeReference("System.Object", true);
+ lexer.NextToken();
+
+#line 1801 "VBNET.ATG"
+ type = new TypeReference("System.Object", true);
break;
}
case 79: {
- Get();
- type = new TypeReference("System.Single", true);
+ lexer.NextToken();
+
+#line 1802 "VBNET.ATG"
+ type = new TypeReference("System.Single", true);
break;
}
case 80: {
- Get();
- type = new TypeReference("System.String", true);
+ lexer.NextToken();
+
+#line 1803 "VBNET.ATG"
+ type = new TypeReference("System.String", true);
break;
}
- default: SynErr(261); break;
+ default: SynErr(264); break;
}
}
- void GetTypeTypeName(out TypeReference typeref) {
- ArrayList rank = null;
- NonArrayTypeName(out typeref, true);
- ArrayTypeModifiers(out rank);
+ void GetTypeTypeName(
+#line 2462 "VBNET.ATG"
+out TypeReference typeref) {
+
+#line 2463 "VBNET.ATG"
+ ArrayList rank = null;
+ NonArrayTypeName(
+#line 2465 "VBNET.ATG"
+out typeref, true);
+ ArrayTypeModifiers(
+#line 2466 "VBNET.ATG"
+out rank);
+
+#line 2467 "VBNET.ATG"
if (rank != null && typeref != null) {
typeref.RankSpecifier = (int[])rank.ToArray(typeof(int));
}
-
+
}
- void ConditionalExpression(out Expression expr) {
+ void ConditionalExpression(
+#line 1736 "VBNET.ATG"
+out Expression expr) {
+
+#line 1738 "VBNET.ATG"
ConditionalExpression conditionalExpression = new ConditionalExpression();
BinaryOperatorExpression binaryOperatorExpression = new BinaryOperatorExpression();
conditionalExpression.StartLocation = binaryOperatorExpression.StartLocation = la.Location;
-
+
Expression condition = null;
Expression trueExpr = null;
Expression falseExpr = null;
-
+
Expect(122);
Expect(25);
- Expr(out condition);
+ Expr(
+#line 1747 "VBNET.ATG"
+out condition);
Expect(12);
- Expr(out trueExpr);
+ Expr(
+#line 1747 "VBNET.ATG"
+out trueExpr);
if (la.kind == 12) {
- Get();
- Expr(out falseExpr);
+ lexer.NextToken();
+ Expr(
+#line 1747 "VBNET.ATG"
+out falseExpr);
}
Expect(26);
+
+#line 1749 "VBNET.ATG"
if(falseExpr != null)
{
conditionalExpression.Condition = condition;
@@ -2987,753 +4449,1309 @@ partial class Parser : AbstractParser
expr = binaryOperatorExpression;
}
-
+
}
- void ArgumentList(out List arguments) {
+ void ArgumentList(
+#line 2394 "VBNET.ATG"
+out List arguments) {
+
+#line 2396 "VBNET.ATG"
arguments = new List();
Expression expr = null;
-
+
if (StartOf(29)) {
- Argument(out expr);
+ Argument(
+#line 2399 "VBNET.ATG"
+out expr);
}
while (la.kind == 12) {
- Get();
- arguments.Add(expr ?? Expression.Null); expr = null;
+ lexer.NextToken();
+
+#line 2400 "VBNET.ATG"
+ arguments.Add(expr ?? Expression.Null); expr = null;
if (StartOf(29)) {
- Argument(out expr);
+ Argument(
+#line 2401 "VBNET.ATG"
+out expr);
}
- if (expr == null) expr = Expression.Null;
+
+#line 2402 "VBNET.ATG"
+ if (expr == null) expr = Expression.Null;
}
- if (expr != null) arguments.Add(expr);
+
+#line 2404 "VBNET.ATG"
+ if (expr != null) arguments.Add(expr);
}
- void ConjunctionExpr(out Expression outExpr) {
+ void ConjunctionExpr(
+#line 1822 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1824 "VBNET.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- NotExpr(out outExpr);
+
+ NotExpr(
+#line 1827 "VBNET.ATG"
+out outExpr);
while (la.kind == 47 || la.kind == 48) {
if (la.kind == 47) {
- Get();
- op = BinaryOperatorType.BitwiseAnd;
+ lexer.NextToken();
+
+#line 1830 "VBNET.ATG"
+ op = BinaryOperatorType.BitwiseAnd;
} else {
- Get();
- op = BinaryOperatorType.LogicalAnd;
+ lexer.NextToken();
+
+#line 1831 "VBNET.ATG"
+ op = BinaryOperatorType.LogicalAnd;
}
- NotExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ NotExpr(
+#line 1833 "VBNET.ATG"
+out expr);
+
+#line 1833 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void NotExpr(out Expression outExpr) {
- UnaryOperatorType uop = UnaryOperatorType.None;
- while (la.kind == 150) {
- Get();
- uop = UnaryOperatorType.Not;
+ void NotExpr(
+#line 1837 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1838 "VBNET.ATG"
+ UnaryOperatorType uop = UnaryOperatorType.None;
+ while (la.kind == 151) {
+ lexer.NextToken();
+
+#line 1839 "VBNET.ATG"
+ uop = UnaryOperatorType.Not;
}
- ComparisonExpr(out outExpr);
+ ComparisonExpr(
+#line 1840 "VBNET.ATG"
+out outExpr);
+
+#line 1841 "VBNET.ATG"
if (uop != UnaryOperatorType.None)
outExpr = new UnaryOperatorExpression(outExpr, uop);
-
+
}
- void ComparisonExpr(out Expression outExpr) {
+ void ComparisonExpr(
+#line 1846 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1848 "VBNET.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- ShiftExpr(out outExpr);
+
+ ShiftExpr(
+#line 1851 "VBNET.ATG"
+out outExpr);
while (StartOf(32)) {
switch (la.kind) {
case 28: {
- Get();
- op = BinaryOperatorType.LessThan;
+ lexer.NextToken();
+
+#line 1854 "VBNET.ATG"
+ op = BinaryOperatorType.LessThan;
break;
}
case 27: {
- Get();
- op = BinaryOperatorType.GreaterThan;
+ lexer.NextToken();
+
+#line 1855 "VBNET.ATG"
+ op = BinaryOperatorType.GreaterThan;
break;
}
case 31: {
- Get();
- op = BinaryOperatorType.LessThanOrEqual;
+ lexer.NextToken();
+
+#line 1856 "VBNET.ATG"
+ op = BinaryOperatorType.LessThanOrEqual;
break;
}
case 30: {
- Get();
- op = BinaryOperatorType.GreaterThanOrEqual;
+ lexer.NextToken();
+
+#line 1857 "VBNET.ATG"
+ op = BinaryOperatorType.GreaterThanOrEqual;
break;
}
case 29: {
- Get();
- op = BinaryOperatorType.InEquality;
+ lexer.NextToken();
+
+#line 1858 "VBNET.ATG"
+ op = BinaryOperatorType.InEquality;
break;
}
case 10: {
- Get();
- op = BinaryOperatorType.Equality;
+ lexer.NextToken();
+
+#line 1859 "VBNET.ATG"
+ op = BinaryOperatorType.Equality;
break;
}
- case 136: {
- Get();
- op = BinaryOperatorType.Like;
+ case 137: {
+ lexer.NextToken();
+
+#line 1860 "VBNET.ATG"
+ op = BinaryOperatorType.Like;
break;
}
case 131: {
- Get();
- op = BinaryOperatorType.ReferenceEquality;
+ lexer.NextToken();
+
+#line 1861 "VBNET.ATG"
+ op = BinaryOperatorType.ReferenceEquality;
break;
}
case 132: {
- Get();
- op = BinaryOperatorType.ReferenceInequality;
+ lexer.NextToken();
+
+#line 1862 "VBNET.ATG"
+ op = BinaryOperatorType.ReferenceInequality;
break;
}
}
if (StartOf(33)) {
- ShiftExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
- } else if (la.kind == 150) {
- Get();
- ShiftExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, new UnaryOperatorExpression(expr, UnaryOperatorType.Not));
- } else SynErr(262);
+ ShiftExpr(
+#line 1865 "VBNET.ATG"
+out expr);
+
+#line 1865 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ } else if (la.kind == 151) {
+ lexer.NextToken();
+ ShiftExpr(
+#line 1868 "VBNET.ATG"
+out expr);
+
+#line 1868 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, new UnaryOperatorExpression(expr, UnaryOperatorType.Not));
+ } else SynErr(265);
}
}
- void ShiftExpr(out Expression outExpr) {
+ void ShiftExpr(
+#line 1873 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1875 "VBNET.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- ConcatenationExpr(out outExpr);
+
+ ConcatenationExpr(
+#line 1878 "VBNET.ATG"
+out outExpr);
while (la.kind == 32 || la.kind == 33) {
if (la.kind == 32) {
- Get();
- op = BinaryOperatorType.ShiftLeft;
+ lexer.NextToken();
+
+#line 1881 "VBNET.ATG"
+ op = BinaryOperatorType.ShiftLeft;
} else {
- Get();
- op = BinaryOperatorType.ShiftRight;
+ lexer.NextToken();
+
+#line 1882 "VBNET.ATG"
+ op = BinaryOperatorType.ShiftRight;
}
- ConcatenationExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ ConcatenationExpr(
+#line 1884 "VBNET.ATG"
+out expr);
+
+#line 1884 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void ConcatenationExpr(out Expression outExpr) {
- Expression expr;
- AdditiveExpr(out outExpr);
+ void ConcatenationExpr(
+#line 1888 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1889 "VBNET.ATG"
+ Expression expr;
+ AdditiveExpr(
+#line 1891 "VBNET.ATG"
+out outExpr);
while (la.kind == 13) {
- Get();
- AdditiveExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.Concat, expr);
+ lexer.NextToken();
+ AdditiveExpr(
+#line 1891 "VBNET.ATG"
+out expr);
+
+#line 1891 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.Concat, expr);
}
}
- void AdditiveExpr(out Expression outExpr) {
+ void AdditiveExpr(
+#line 1894 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1896 "VBNET.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- ModuloExpr(out outExpr);
+
+ ModuloExpr(
+#line 1899 "VBNET.ATG"
+out outExpr);
while (la.kind == 18 || la.kind == 19) {
if (la.kind == 19) {
- Get();
- op = BinaryOperatorType.Add;
+ lexer.NextToken();
+
+#line 1902 "VBNET.ATG"
+ op = BinaryOperatorType.Add;
} else {
- Get();
- op = BinaryOperatorType.Subtract;
+ lexer.NextToken();
+
+#line 1903 "VBNET.ATG"
+ op = BinaryOperatorType.Subtract;
}
- ModuloExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ ModuloExpr(
+#line 1905 "VBNET.ATG"
+out expr);
+
+#line 1905 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void ModuloExpr(out Expression outExpr) {
- Expression expr;
- IntegerDivisionExpr(out outExpr);
- while (la.kind == 140) {
- Get();
- IntegerDivisionExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.Modulus, expr);
+ void ModuloExpr(
+#line 1909 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1910 "VBNET.ATG"
+ Expression expr;
+ IntegerDivisionExpr(
+#line 1912 "VBNET.ATG"
+out outExpr);
+ while (la.kind == 141) {
+ lexer.NextToken();
+ IntegerDivisionExpr(
+#line 1912 "VBNET.ATG"
+out expr);
+
+#line 1912 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.Modulus, expr);
}
}
- void IntegerDivisionExpr(out Expression outExpr) {
- Expression expr;
- MultiplicativeExpr(out outExpr);
+ void IntegerDivisionExpr(
+#line 1915 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1916 "VBNET.ATG"
+ Expression expr;
+ MultiplicativeExpr(
+#line 1918 "VBNET.ATG"
+out outExpr);
while (la.kind == 15) {
- Get();
- MultiplicativeExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.DivideInteger, expr);
+ lexer.NextToken();
+ MultiplicativeExpr(
+#line 1918 "VBNET.ATG"
+out expr);
+
+#line 1918 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.DivideInteger, expr);
}
}
- void MultiplicativeExpr(out Expression outExpr) {
+ void MultiplicativeExpr(
+#line 1921 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1923 "VBNET.ATG"
Expression expr;
BinaryOperatorType op = BinaryOperatorType.None;
-
- UnaryExpr(out outExpr);
+
+ UnaryExpr(
+#line 1926 "VBNET.ATG"
+out outExpr);
while (la.kind == 14 || la.kind == 22) {
if (la.kind == 22) {
- Get();
- op = BinaryOperatorType.Multiply;
+ lexer.NextToken();
+
+#line 1929 "VBNET.ATG"
+ op = BinaryOperatorType.Multiply;
} else {
- Get();
- op = BinaryOperatorType.Divide;
+ lexer.NextToken();
+
+#line 1930 "VBNET.ATG"
+ op = BinaryOperatorType.Divide;
}
- UnaryExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, op, expr);
+ UnaryExpr(
+#line 1932 "VBNET.ATG"
+out expr);
+
+#line 1932 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, op, expr);
}
}
- void UnaryExpr(out Expression uExpr) {
+ void UnaryExpr(
+#line 1936 "VBNET.ATG"
+out Expression uExpr) {
+
+#line 1938 "VBNET.ATG"
Expression expr;
UnaryOperatorType uop = UnaryOperatorType.None;
bool isUOp = false;
-
+
while (la.kind == 18 || la.kind == 19 || la.kind == 22) {
if (la.kind == 19) {
- Get();
- uop = UnaryOperatorType.Plus; isUOp = true;
+ lexer.NextToken();
+
+#line 1942 "VBNET.ATG"
+ uop = UnaryOperatorType.Plus; isUOp = true;
} else if (la.kind == 18) {
- Get();
- uop = UnaryOperatorType.Minus; isUOp = true;
+ lexer.NextToken();
+
+#line 1943 "VBNET.ATG"
+ uop = UnaryOperatorType.Minus; isUOp = true;
} else {
- Get();
+ lexer.NextToken();
+
+#line 1944 "VBNET.ATG"
uop = UnaryOperatorType.Dereference; isUOp = true;
}
}
- ExponentiationExpr(out expr);
+ ExponentiationExpr(
+#line 1946 "VBNET.ATG"
+out expr);
+
+#line 1948 "VBNET.ATG"
if (isUOp) {
uExpr = new UnaryOperatorExpression(expr, uop);
} else {
uExpr = expr;
}
-
+
}
- void ExponentiationExpr(out Expression outExpr) {
- Expression expr;
- SimpleExpr(out outExpr);
+ void ExponentiationExpr(
+#line 1956 "VBNET.ATG"
+out Expression outExpr) {
+
+#line 1957 "VBNET.ATG"
+ Expression expr;
+ SimpleExpr(
+#line 1959 "VBNET.ATG"
+out outExpr);
while (la.kind == 20) {
- Get();
- SimpleExpr(out expr);
- outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.Power, expr);
+ lexer.NextToken();
+ SimpleExpr(
+#line 1959 "VBNET.ATG"
+out expr);
+
+#line 1959 "VBNET.ATG"
+ outExpr = new BinaryOperatorExpression(outExpr, BinaryOperatorType.Power, expr);
}
}
- void NormalOrReDimArgumentList(out List arguments, out bool canBeNormal, out bool canBeRedim) {
+ void NormalOrReDimArgumentList(
+#line 2408 "VBNET.ATG"
+out List arguments, out bool canBeNormal, out bool canBeRedim) {
+
+#line 2410 "VBNET.ATG"
arguments = new List();
canBeNormal = true; canBeRedim = !IsNamedAssign();
Expression expr = null;
-
+
if (StartOf(29)) {
- Argument(out expr);
- if (la.kind == 201) {
- Get();
- EnsureIsZero(expr); canBeNormal = false;
- Expr(out expr);
+ Argument(
+#line 2415 "VBNET.ATG"
+out expr);
+ if (la.kind == 202) {
+ lexer.NextToken();
+
+#line 2416 "VBNET.ATG"
+ EnsureIsZero(expr); canBeNormal = false;
+ Expr(
+#line 2417 "VBNET.ATG"
+out expr);
}
}
while (la.kind == 12) {
- Get();
- if (expr == null) canBeRedim = false;
- arguments.Add(expr ?? Expression.Null); expr = null;
- canBeRedim &= !IsNamedAssign();
+ lexer.NextToken();
+
+#line 2420 "VBNET.ATG"
+ if (expr == null) canBeRedim = false;
+
+#line 2421 "VBNET.ATG"
+ arguments.Add(expr ?? Expression.Null); expr = null;
+
+#line 2422 "VBNET.ATG"
+ canBeRedim &= !IsNamedAssign();
if (StartOf(29)) {
- Argument(out expr);
- if (la.kind == 201) {
- Get();
- EnsureIsZero(expr); canBeNormal = false;
- Expr(out expr);
+ Argument(
+#line 2423 "VBNET.ATG"
+out expr);
+ if (la.kind == 202) {
+ lexer.NextToken();
+
+#line 2424 "VBNET.ATG"
+ EnsureIsZero(expr); canBeNormal = false;
+ Expr(
+#line 2425 "VBNET.ATG"
+out expr);
}
}
- if (expr == null) { canBeRedim = false; expr = Expression.Null; }
+
+#line 2427 "VBNET.ATG"
+ if (expr == null) { canBeRedim = false; expr = Expression.Null; }
}
- if (expr != null) arguments.Add(expr); else canBeRedim = false;
+
+#line 2429 "VBNET.ATG"
+ if (expr != null) arguments.Add(expr); else canBeRedim = false;
}
- void ArrayTypeModifiers(out ArrayList arrayModifiers) {
+ void ArrayTypeModifiers(
+#line 2536 "VBNET.ATG"
+out ArrayList arrayModifiers) {
+
+#line 2538 "VBNET.ATG"
arrayModifiers = new ArrayList();
int i = 0;
-
- while (IsDims()) {
+
+ while (
+#line 2541 "VBNET.ATG"
+IsDims()) {
Expect(25);
if (la.kind == 12 || la.kind == 26) {
- RankList(out i);
+ RankList(
+#line 2543 "VBNET.ATG"
+out i);
}
- arrayModifiers.Add(i);
+#line 2545 "VBNET.ATG"
+ arrayModifiers.Add(i);
+
Expect(26);
}
+
+#line 2550 "VBNET.ATG"
if(arrayModifiers.Count == 0) {
arrayModifiers = null;
}
-
+
}
- void MemberInitializer(out MemberInitializerExpression memberInitializer) {
+ void MemberInitializer(
+#line 2375 "VBNET.ATG"
+out MemberInitializerExpression memberInitializer) {
+
+#line 2377 "VBNET.ATG"
memberInitializer = new MemberInitializerExpression();
memberInitializer.StartLocation = la.Location;
Expression initExpr = null;
bool isKey = false;
string name = null;
-
+
Expect(16);
- IdentifierOrKeyword(out name);
+ IdentifierOrKeyword(
+#line 2384 "VBNET.ATG"
+out name);
Expect(10);
- Expr(out initExpr);
+ Expr(
+#line 2384 "VBNET.ATG"
+out initExpr);
+
+#line 2386 "VBNET.ATG"
memberInitializer.Name = name;
memberInitializer.Expression = initExpr;
memberInitializer.IsKey = isKey;
memberInitializer.EndLocation = t.EndLocation;
-
+
}
- void FromOrAggregateQueryOperator(List middleClauses) {
+ void FromOrAggregateQueryOperator(
+#line 2064 "VBNET.ATG"
+List middleClauses) {
+
+#line 2066 "VBNET.ATG"
QueryExpressionFromClause fromClause = null;
QueryExpressionAggregateClause aggregateClause = null;
-
+
if (la.kind == 113) {
- FromQueryOperator(out fromClause);
- middleClauses.Add(fromClause);
+ FromQueryOperator(
+#line 2069 "VBNET.ATG"
+out fromClause);
+
+#line 2070 "VBNET.ATG"
+ middleClauses.Add(fromClause);
} else if (la.kind == 45) {
- AggregateQueryOperator(out aggregateClause);
- middleClauses.Add(aggregateClause);
- } else SynErr(263);
+ AggregateQueryOperator(
+#line 2071 "VBNET.ATG"
+out aggregateClause);
+
+#line 2072 "VBNET.ATG"
+ middleClauses.Add(aggregateClause);
+ } else SynErr(266);
}
- void QueryOperator(List middleClauses) {
+ void QueryOperator(
+#line 2075 "VBNET.ATG"
+List middleClauses) {
+
+#line 2077 "VBNET.ATG"
QueryExpressionJoinVBClause joinClause = null;
QueryExpressionGroupVBClause groupByClause = null;
QueryExpressionPartitionVBClause partitionClause = null;
QueryExpressionGroupJoinVBClause groupJoinClause = null;
QueryExpressionFromClause fromClause = null;
QueryExpressionAggregateClause aggregateClause = null;
-
+
if (la.kind == 113) {
- FromQueryOperator(out fromClause);
- middleClauses.Add(fromClause);
+ FromQueryOperator(
+#line 2084 "VBNET.ATG"
+out fromClause);
+
+#line 2085 "VBNET.ATG"
+ middleClauses.Add(fromClause);
} else if (la.kind == 45) {
- AggregateQueryOperator(out aggregateClause);
- middleClauses.Add(aggregateClause);
- } else if (la.kind == 182) {
- SelectQueryOperator(middleClauses);
+ AggregateQueryOperator(
+#line 2086 "VBNET.ATG"
+out aggregateClause);
+
+#line 2087 "VBNET.ATG"
+ middleClauses.Add(aggregateClause);
+ } else if (la.kind == 183) {
+ SelectQueryOperator(
+#line 2088 "VBNET.ATG"
+middleClauses);
} else if (la.kind == 94) {
- DistinctQueryOperator(middleClauses);
- } else if (la.kind == 215) {
- WhereQueryOperator(middleClauses);
- } else if (la.kind == 162) {
- OrderByQueryOperator(middleClauses);
- } else if (la.kind == 188 || la.kind == 197) {
- PartitionQueryOperator(out partitionClause);
- middleClauses.Add(partitionClause);
- } else if (la.kind == 134) {
- LetQueryOperator(middleClauses);
+ DistinctQueryOperator(
+#line 2089 "VBNET.ATG"
+middleClauses);
+ } else if (la.kind == 216) {
+ WhereQueryOperator(
+#line 2090 "VBNET.ATG"
+middleClauses);
+ } else if (la.kind == 163) {
+ OrderByQueryOperator(
+#line 2091 "VBNET.ATG"
+middleClauses);
+ } else if (la.kind == 189 || la.kind == 198) {
+ PartitionQueryOperator(
+#line 2092 "VBNET.ATG"
+out partitionClause);
+
+#line 2093 "VBNET.ATG"
+ middleClauses.Add(partitionClause);
+ } else if (la.kind == 135) {
+ LetQueryOperator(
+#line 2094 "VBNET.ATG"
+middleClauses);
} else if (la.kind == 133) {
- JoinQueryOperator(out joinClause);
- middleClauses.Add(joinClause);
- } else if (la.kind == Tokens.Group && Peek(1).kind == Tokens.Join) {
- GroupJoinQueryOperator(out groupJoinClause);
- middleClauses.Add(groupJoinClause);
+ JoinQueryOperator(
+#line 2095 "VBNET.ATG"
+out joinClause);
+
+#line 2096 "VBNET.ATG"
+ middleClauses.Add(joinClause);
+ } else if (
+#line 2097 "VBNET.ATG"
+la.kind == Tokens.Group && Peek(1).kind == Tokens.Join) {
+ GroupJoinQueryOperator(
+#line 2097 "VBNET.ATG"
+out groupJoinClause);
+
+#line 2098 "VBNET.ATG"
+ middleClauses.Add(groupJoinClause);
} else if (la.kind == 120) {
- GroupByQueryOperator(out groupByClause);
- middleClauses.Add(groupByClause);
- } else SynErr(264);
+ GroupByQueryOperator(
+#line 2099 "VBNET.ATG"
+out groupByClause);
+
+#line 2100 "VBNET.ATG"
+ middleClauses.Add(groupByClause);
+ } else SynErr(267);
}
- void FromQueryOperator(out QueryExpressionFromClause fromClause) {
+ void FromQueryOperator(
+#line 2175 "VBNET.ATG"
+out QueryExpressionFromClause fromClause) {
+
+#line 2177 "VBNET.ATG"
fromClause = new QueryExpressionFromClause();
fromClause.StartLocation = la.Location;
-
+
Expect(113);
- CollectionRangeVariableDeclarationList(fromClause.Sources);
- fromClause.EndLocation = t.EndLocation;
+ CollectionRangeVariableDeclarationList(
+#line 2180 "VBNET.ATG"
+fromClause.Sources);
+#line 2182 "VBNET.ATG"
+ fromClause.EndLocation = t.EndLocation;
+
}
- void AggregateQueryOperator(out QueryExpressionAggregateClause aggregateClause) {
+ void AggregateQueryOperator(
+#line 2244 "VBNET.ATG"
+out QueryExpressionAggregateClause aggregateClause) {
+
+#line 2246 "VBNET.ATG"
aggregateClause = new QueryExpressionAggregateClause();
aggregateClause.IntoVariables = new List();
aggregateClause.StartLocation = la.Location;
CollectionRangeVariable source;
-
+
Expect(45);
- CollectionRangeVariableDeclaration(out source);
- aggregateClause.Source = source;
+ CollectionRangeVariableDeclaration(
+#line 2251 "VBNET.ATG"
+out source);
+#line 2253 "VBNET.ATG"
+ aggregateClause.Source = source;
+
while (StartOf(30)) {
- QueryOperator(aggregateClause.MiddleClauses);
+ QueryOperator(
+#line 2256 "VBNET.ATG"
+aggregateClause.MiddleClauses);
}
Expect(130);
- ExpressionRangeVariableDeclarationList(aggregateClause.IntoVariables);
- aggregateClause.EndLocation = t.EndLocation;
+ ExpressionRangeVariableDeclarationList(
+#line 2258 "VBNET.ATG"
+aggregateClause.IntoVariables);
+#line 2260 "VBNET.ATG"
+ aggregateClause.EndLocation = t.EndLocation;
+
}
- void SelectQueryOperator(List middleClauses) {
+ void SelectQueryOperator(
+#line 2186 "VBNET.ATG"
+List middleClauses) {
+
+#line 2188 "VBNET.ATG"
QueryExpressionSelectVBClause selectClause = new QueryExpressionSelectVBClause();
selectClause.StartLocation = la.Location;
+
+ Expect(183);
+ ExpressionRangeVariableDeclarationList(
+#line 2191 "VBNET.ATG"
+selectClause.Variables);
- Expect(182);
- ExpressionRangeVariableDeclarationList(selectClause.Variables);
+#line 2193 "VBNET.ATG"
selectClause.EndLocation = t.Location;
middleClauses.Add(selectClause);
-
+
}
- void DistinctQueryOperator(List middleClauses) {
+ void DistinctQueryOperator(
+#line 2198 "VBNET.ATG"
+List middleClauses) {
+
+#line 2200 "VBNET.ATG"
QueryExpressionDistinctClause distinctClause = new QueryExpressionDistinctClause();
distinctClause.StartLocation = la.Location;
-
+
Expect(94);
+
+#line 2205 "VBNET.ATG"
distinctClause.EndLocation = t.EndLocation;
middleClauses.Add(distinctClause);
-
+
}
- void WhereQueryOperator(List middleClauses) {
+ void WhereQueryOperator(
+#line 2210 "VBNET.ATG"
+List middleClauses) {
+
+#line 2212 "VBNET.ATG"
QueryExpressionWhereClause whereClause = new QueryExpressionWhereClause();
whereClause.StartLocation = la.Location;
Expression operand = null;
+
+ Expect(216);
+ Expr(
+#line 2216 "VBNET.ATG"
+out operand);
- Expect(215);
- Expr(out operand);
+#line 2218 "VBNET.ATG"
whereClause.Condition = operand;
whereClause.EndLocation = t.EndLocation;
-
+
middleClauses.Add(whereClause);
-
+
}
- void OrderByQueryOperator(List middleClauses) {
+ void OrderByQueryOperator(
+#line 2103 "VBNET.ATG"
+List middleClauses) {
+
+#line 2105 "VBNET.ATG"
QueryExpressionOrderClause orderClause = new QueryExpressionOrderClause();
orderClause.StartLocation = la.Location;
List orderings = null;
-
- Expect(162);
+
+ Expect(163);
Expect(57);
- OrderExpressionList(out orderings);
+ OrderExpressionList(
+#line 2109 "VBNET.ATG"
+out orderings);
+
+#line 2111 "VBNET.ATG"
orderClause.Orderings = orderings;
orderClause.EndLocation = t.EndLocation;
middleClauses.Add(orderClause);
-
+
}
- void PartitionQueryOperator(out QueryExpressionPartitionVBClause partitionClause) {
+ void PartitionQueryOperator(
+#line 2225 "VBNET.ATG"
+out QueryExpressionPartitionVBClause partitionClause) {
+
+#line 2227 "VBNET.ATG"
partitionClause = new QueryExpressionPartitionVBClause();
partitionClause.StartLocation = la.Location;
Expression expr = null;
+
+ if (la.kind == 198) {
+ lexer.NextToken();
+
+#line 2232 "VBNET.ATG"
+ partitionClause.PartitionType = QueryExpressionPartitionType.Take;
+ if (la.kind == 217) {
+ lexer.NextToken();
+
+#line 2233 "VBNET.ATG"
+ partitionClause.PartitionType = QueryExpressionPartitionType.TakeWhile;
+ }
+ } else if (la.kind == 189) {
+ lexer.NextToken();
- if (la.kind == 197) {
- Get();
- partitionClause.PartitionType = QueryExpressionPartitionType.Take;
- if (la.kind == 216) {
- Get();
- partitionClause.PartitionType = QueryExpressionPartitionType.TakeWhile;
- }
- } else if (la.kind == 188) {
- Get();
- partitionClause.PartitionType = QueryExpressionPartitionType.Skip;
- if (la.kind == 216) {
- Get();
- partitionClause.PartitionType = QueryExpressionPartitionType.SkipWhile;
- }
- } else SynErr(265);
- Expr(out expr);
+#line 2234 "VBNET.ATG"
+ partitionClause.PartitionType = QueryExpressionPartitionType.Skip;
+ if (la.kind == 217) {
+ lexer.NextToken();
+
+#line 2235 "VBNET.ATG"
+ partitionClause.PartitionType = QueryExpressionPartitionType.SkipWhile;
+ }
+ } else SynErr(268);
+ Expr(
+#line 2237 "VBNET.ATG"
+out expr);
+
+#line 2239 "VBNET.ATG"
partitionClause.Expression = expr;
partitionClause.EndLocation = t.EndLocation;
-
+
}
- void LetQueryOperator(List middleClauses) {
+ void LetQueryOperator(
+#line 2264 "VBNET.ATG"
+List middleClauses) {
+
+#line 2266 "VBNET.ATG"
QueryExpressionLetVBClause letClause = new QueryExpressionLetVBClause();
letClause.StartLocation = la.Location;
+
+ Expect(135);
+ ExpressionRangeVariableDeclarationList(
+#line 2269 "VBNET.ATG"
+letClause.Variables);
- Expect(134);
- ExpressionRangeVariableDeclarationList(letClause.Variables);
+#line 2271 "VBNET.ATG"
letClause.EndLocation = t.EndLocation;
middleClauses.Add(letClause);
-
+
}
- void JoinQueryOperator(out QueryExpressionJoinVBClause joinClause) {
+ void JoinQueryOperator(
+#line 2308 "VBNET.ATG"
+out QueryExpressionJoinVBClause joinClause) {
+
+#line 2310 "VBNET.ATG"
joinClause = new QueryExpressionJoinVBClause();
joinClause.StartLocation = la.Location;
CollectionRangeVariable joinVariable = null;
QueryExpressionJoinVBClause subJoin = null;
QueryExpressionJoinConditionVB condition = null;
-
-
+
+
Expect(133);
- CollectionRangeVariableDeclaration(out joinVariable);
- joinClause.JoinVariable = joinVariable;
+ CollectionRangeVariableDeclaration(
+#line 2317 "VBNET.ATG"
+out joinVariable);
+
+#line 2318 "VBNET.ATG"
+ joinClause.JoinVariable = joinVariable;
if (la.kind == 133) {
- JoinQueryOperator(out subJoin);
- joinClause.SubJoin = subJoin;
+ JoinQueryOperator(
+#line 2320 "VBNET.ATG"
+out subJoin);
+
+#line 2321 "VBNET.ATG"
+ joinClause.SubJoin = subJoin;
}
- Expect(157);
- JoinCondition(out condition);
- SafeAdd(joinClause, joinClause.Conditions, condition);
+ Expect(158);
+ JoinCondition(
+#line 2324 "VBNET.ATG"
+out condition);
+
+#line 2325 "VBNET.ATG"
+ SafeAdd(joinClause, joinClause.Conditions, condition);
while (la.kind == 47) {
- Get();
- JoinCondition(out condition);
- SafeAdd(joinClause, joinClause.Conditions, condition);
+ lexer.NextToken();
+ JoinCondition(
+#line 2327 "VBNET.ATG"
+out condition);
+
+#line 2328 "VBNET.ATG"
+ SafeAdd(joinClause, joinClause.Conditions, condition);
}
- joinClause.EndLocation = t.EndLocation;
+#line 2331 "VBNET.ATG"
+ joinClause.EndLocation = t.EndLocation;
+
}
- void GroupJoinQueryOperator(out QueryExpressionGroupJoinVBClause groupJoinClause) {
+ void GroupJoinQueryOperator(
+#line 2161 "VBNET.ATG"
+out QueryExpressionGroupJoinVBClause groupJoinClause) {
+
+#line 2163 "VBNET.ATG"
groupJoinClause = new QueryExpressionGroupJoinVBClause();
groupJoinClause.StartLocation = la.Location;
QueryExpressionJoinVBClause joinClause = null;
-
+
Expect(120);
- JoinQueryOperator(out joinClause);
+ JoinQueryOperator(
+#line 2167 "VBNET.ATG"
+out joinClause);
Expect(130);
- ExpressionRangeVariableDeclarationList(groupJoinClause.IntoVariables);
+ ExpressionRangeVariableDeclarationList(
+#line 2168 "VBNET.ATG"
+groupJoinClause.IntoVariables);
+
+#line 2170 "VBNET.ATG"
groupJoinClause.JoinClause = joinClause;
groupJoinClause.EndLocation = t.EndLocation;
-
+
}
- void GroupByQueryOperator(out QueryExpressionGroupVBClause groupByClause) {
+ void GroupByQueryOperator(
+#line 2148 "VBNET.ATG"
+out QueryExpressionGroupVBClause groupByClause) {
+
+#line 2150 "VBNET.ATG"
groupByClause = new QueryExpressionGroupVBClause();
groupByClause.StartLocation = la.Location;
-
+
Expect(120);
- ExpressionRangeVariableDeclarationList(groupByClause.GroupVariables);
+ ExpressionRangeVariableDeclarationList(
+#line 2153 "VBNET.ATG"
+groupByClause.GroupVariables);
Expect(57);
- ExpressionRangeVariableDeclarationList(groupByClause.ByVariables);
+ ExpressionRangeVariableDeclarationList(
+#line 2154 "VBNET.ATG"
+groupByClause.ByVariables);
Expect(130);
- ExpressionRangeVariableDeclarationList(groupByClause.IntoVariables);
- groupByClause.EndLocation = t.EndLocation;
+ ExpressionRangeVariableDeclarationList(
+#line 2155 "VBNET.ATG"
+groupByClause.IntoVariables);
+#line 2157 "VBNET.ATG"
+ groupByClause.EndLocation = t.EndLocation;
+
}
- void OrderExpressionList(out List orderings) {
+ void OrderExpressionList(
+#line 2117 "VBNET.ATG"
+out List orderings) {
+
+#line 2119 "VBNET.ATG"
orderings = new List();
QueryExpressionOrdering ordering = null;
+
+ OrderExpression(
+#line 2122 "VBNET.ATG"
+out ordering);
- OrderExpression(out ordering);
- orderings.Add(ordering);
+#line 2123 "VBNET.ATG"
+ orderings.Add(ordering);
while (la.kind == 12) {
- Get();
- OrderExpression(out ordering);
- orderings.Add(ordering);
+ lexer.NextToken();
+ OrderExpression(
+#line 2125 "VBNET.ATG"
+out ordering);
+
+#line 2126 "VBNET.ATG"
+ orderings.Add(ordering);
}
}
- void OrderExpression(out QueryExpressionOrdering ordering) {
+ void OrderExpression(
+#line 2130 "VBNET.ATG"
+out QueryExpressionOrdering ordering) {
+
+#line 2132 "VBNET.ATG"
ordering = new QueryExpressionOrdering();
ordering.StartLocation = la.Location;
ordering.Direction = QueryExpressionOrderingDirection.None;
Expression orderExpr = null;
+
+ Expr(
+#line 2137 "VBNET.ATG"
+out orderExpr);
- Expr(out orderExpr);
+#line 2139 "VBNET.ATG"
ordering.Criteria = orderExpr;
-
+
if (la.kind == 51 || la.kind == 91) {
if (la.kind == 51) {
- Get();
- ordering.Direction = QueryExpressionOrderingDirection.Ascending;
+ lexer.NextToken();
+
+#line 2142 "VBNET.ATG"
+ ordering.Direction = QueryExpressionOrderingDirection.Ascending;
} else {
- Get();
- ordering.Direction = QueryExpressionOrderingDirection.Descending;
+ lexer.NextToken();
+
+#line 2143 "VBNET.ATG"
+ ordering.Direction = QueryExpressionOrderingDirection.Descending;
}
}
- ordering.EndLocation = t.EndLocation;
+
+#line 2145 "VBNET.ATG"
+ ordering.EndLocation = t.EndLocation;
}
- void ExpressionRangeVariableDeclarationList(List variables) {
+ void ExpressionRangeVariableDeclarationList(
+#line 2276 "VBNET.ATG"
+List variables) {
+
+#line 2278 "VBNET.ATG"
ExpressionRangeVariable variable = null;
+
+ ExpressionRangeVariableDeclaration(
+#line 2280 "VBNET.ATG"
+out variable);
- ExpressionRangeVariableDeclaration(out variable);
- variables.Add(variable);
+#line 2281 "VBNET.ATG"
+ variables.Add(variable);
while (la.kind == 12) {
- Get();
- ExpressionRangeVariableDeclaration(out variable);
- variables.Add(variable);
+ lexer.NextToken();
+ ExpressionRangeVariableDeclaration(
+#line 2282 "VBNET.ATG"
+out variable);
+
+#line 2282 "VBNET.ATG"
+ variables.Add(variable);
}
}
- void CollectionRangeVariableDeclarationList(List rangeVariables) {
- CollectionRangeVariable variableDeclaration;
- CollectionRangeVariableDeclaration(out variableDeclaration);
- rangeVariables.Add(variableDeclaration);
+ void CollectionRangeVariableDeclarationList(
+#line 2335 "VBNET.ATG"
+List rangeVariables) {
+
+#line 2336 "VBNET.ATG"
+ CollectionRangeVariable variableDeclaration;
+ CollectionRangeVariableDeclaration(
+#line 2338 "VBNET.ATG"
+out variableDeclaration);
+
+#line 2339 "VBNET.ATG"
+ rangeVariables.Add(variableDeclaration);
while (la.kind == 12) {
- Get();
- CollectionRangeVariableDeclaration(out variableDeclaration);
- rangeVariables.Add(variableDeclaration);
+ lexer.NextToken();
+ CollectionRangeVariableDeclaration(
+#line 2340 "VBNET.ATG"
+out variableDeclaration);
+
+#line 2340 "VBNET.ATG"
+ rangeVariables.Add(variableDeclaration);
}
}
- void CollectionRangeVariableDeclaration(out CollectionRangeVariable rangeVariable) {
+ void CollectionRangeVariableDeclaration(
+#line 2343 "VBNET.ATG"
+out CollectionRangeVariable rangeVariable) {
+
+#line 2345 "VBNET.ATG"
rangeVariable = new CollectionRangeVariable();
rangeVariable.StartLocation = la.Location;
TypeReference typeName = null;
Expression inExpr = null;
-
+
Identifier();
- rangeVariable.Identifier = t.val;
+
+#line 2350 "VBNET.ATG"
+ rangeVariable.Identifier = t.val;
if (la.kind == 50) {
- Get();
- TypeName(out typeName);
- rangeVariable.Type = typeName;
+ lexer.NextToken();
+ TypeName(
+#line 2351 "VBNET.ATG"
+out typeName);
+
+#line 2351 "VBNET.ATG"
+ rangeVariable.Type = typeName;
}
Expect(125);
- Expr(out inExpr);
+ Expr(
+#line 2352 "VBNET.ATG"
+out inExpr);
+
+#line 2354 "VBNET.ATG"
rangeVariable.Expression = inExpr;
rangeVariable.EndLocation = t.EndLocation;
-
+
}
- void ExpressionRangeVariableDeclaration(out ExpressionRangeVariable variable) {
+ void ExpressionRangeVariableDeclaration(
+#line 2285 "VBNET.ATG"
+out ExpressionRangeVariable variable) {
+
+#line 2287 "VBNET.ATG"
variable = new ExpressionRangeVariable();
variable.StartLocation = la.Location;
Expression rhs = null;
TypeReference typeName = null;
-
- if (IsIdentifiedExpressionRange()) {
+
+ if (
+#line 2293 "VBNET.ATG"
+IsIdentifiedExpressionRange()) {
Identifier();
- variable.Identifier = t.val;
+
+#line 2294 "VBNET.ATG"
+ variable.Identifier = t.val;
if (la.kind == 50) {
- Get();
- TypeName(out typeName);
- variable.Type = typeName;
+ lexer.NextToken();
+ TypeName(
+#line 2296 "VBNET.ATG"
+out typeName);
+
+#line 2297 "VBNET.ATG"
+ variable.Type = typeName;
}
Expect(10);
}
- Expr(out rhs);
+ Expr(
+#line 2301 "VBNET.ATG"
+out rhs);
+
+#line 2303 "VBNET.ATG"
variable.Expression = rhs;
variable.EndLocation = t.EndLocation;
-
+
}
- void JoinCondition(out QueryExpressionJoinConditionVB condition) {
+ void JoinCondition(
+#line 2359 "VBNET.ATG"
+out QueryExpressionJoinConditionVB condition) {
+
+#line 2361 "VBNET.ATG"
condition = new QueryExpressionJoinConditionVB();
condition.StartLocation = la.Location;
-
+
Expression lhs = null;
Expression rhs = null;
-
- Expr(out lhs);
+
+ Expr(
+#line 2367 "VBNET.ATG"
+out lhs);
Expect(103);
- Expr(out rhs);
+ Expr(
+#line 2367 "VBNET.ATG"
+out rhs);
+
+#line 2369 "VBNET.ATG"
condition.LeftSide = lhs;
condition.RightSide = rhs;
condition.EndLocation = t.EndLocation;
-
+
}
- void Argument(out Expression argumentexpr) {
+ void Argument(
+#line 2433 "VBNET.ATG"
+out Expression argumentexpr) {
+
+#line 2435 "VBNET.ATG"
Expression expr;
argumentexpr = null;
string name;
-
- if (IsNamedAssign()) {
+
+ if (
+#line 2439 "VBNET.ATG"
+IsNamedAssign()) {
Identifier();
- name = t.val;
+
+#line 2439 "VBNET.ATG"
+ name = t.val;
Expect(11);
Expect(10);
- Expr(out expr);
- argumentexpr = new NamedArgumentExpression(name, expr);
+ Expr(
+#line 2439 "VBNET.ATG"
+out expr);
+#line 2441 "VBNET.ATG"
+ argumentexpr = new NamedArgumentExpression(name, expr);
+
} else if (StartOf(29)) {
- Expr(out argumentexpr);
- } else SynErr(266);
+ Expr(
+#line 2444 "VBNET.ATG"
+out argumentexpr);
+ } else SynErr(269);
}
- void QualIdentAndTypeArguments(out TypeReference typeref, bool canBeUnbound) {
- string name; typeref = null;
- Qualident(out name);
- typeref = new TypeReference(name);
- if (la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
- Expect(25);
- Expect(155);
- if (canBeUnbound && (la.kind == Tokens.CloseParenthesis || la.kind == Tokens.Comma)) {
- typeref.GenericTypes.Add(NullTypeReference.Instance);
+ void QualIdentAndTypeArguments(
+#line 2510 "VBNET.ATG"
+out TypeReference typeref, bool canBeUnbound) {
+
+#line 2511 "VBNET.ATG"
+ string name; typeref = null;
+ Qualident(
+#line 2513 "VBNET.ATG"
+out name);
+
+#line 2514 "VBNET.ATG"
+ typeref = new TypeReference(name);
+ if (
+#line 2515 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
+ lexer.NextToken();
+ Expect(156);
+ if (
+#line 2517 "VBNET.ATG"
+canBeUnbound && (la.kind == Tokens.CloseParenthesis || la.kind == Tokens.Comma)) {
+
+#line 2518 "VBNET.ATG"
+ typeref.GenericTypes.Add(NullTypeReference.Instance);
while (la.kind == 12) {
- Get();
- typeref.GenericTypes.Add(NullTypeReference.Instance);
+ lexer.NextToken();
+
+#line 2519 "VBNET.ATG"
+ typeref.GenericTypes.Add(NullTypeReference.Instance);
}
} else if (StartOf(8)) {
- TypeArgumentList(typeref.GenericTypes);
- } else SynErr(267);
+ TypeArgumentList(
+#line 2520 "VBNET.ATG"
+typeref.GenericTypes);
+ } else SynErr(270);
Expect(26);
}
}
- void RankList(out int i) {
- i = 0;
+ void RankList(
+#line 2557 "VBNET.ATG"
+out int i) {
+
+#line 2558 "VBNET.ATG"
+ i = 0;
while (la.kind == 12) {
- Get();
- ++i;
+ lexer.NextToken();
+
+#line 2559 "VBNET.ATG"
+ ++i;
}
}
- void Attribute(out ASTAttribute attribute) {
+ void Attribute(
+#line 2598 "VBNET.ATG"
+out ASTAttribute attribute) {
+
+#line 2599 "VBNET.ATG"
string name;
List positional = new List();
List named = new List();
-
+
if (la.kind == 117) {
- Get();
+ lexer.NextToken();
Expect(16);
}
- Qualident(out name);
+ Qualident(
+#line 2604 "VBNET.ATG"
+out name);
if (la.kind == 25) {
- AttributeArguments(positional, named);
+ AttributeArguments(
+#line 2605 "VBNET.ATG"
+positional, named);
}
- attribute = new ASTAttribute(name, positional, named);
+#line 2607 "VBNET.ATG"
+ attribute = new ASTAttribute(name, positional, named);
+
}
- void AttributeArguments(List positional, List named) {
+ void AttributeArguments(
+#line 2612 "VBNET.ATG"
+List positional, List named) {
+
+#line 2614 "VBNET.ATG"
bool nameFound = false;
string name = "";
Expression expr;
-
+
Expect(25);
- if (IsNotClosingParenthesis()) {
- if (IsNamedAssign()) {
- nameFound = true;
- IdentifierOrKeyword(out name);
+ if (
+#line 2620 "VBNET.ATG"
+IsNotClosingParenthesis()) {
+ if (
+#line 2622 "VBNET.ATG"
+IsNamedAssign()) {
+
+#line 2622 "VBNET.ATG"
+ nameFound = true;
+ IdentifierOrKeyword(
+#line 2623 "VBNET.ATG"
+out name);
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
Expect(10);
}
- Expr(out expr);
+ Expr(
+#line 2625 "VBNET.ATG"
+out expr);
+
+#line 2627 "VBNET.ATG"
if (expr != null) {
if (string.IsNullOrEmpty(name)) { positional.Add(expr); }
else { named.Add(new NamedArgumentExpression(name, expr)); name = ""; }
}
-
+
while (la.kind == 12) {
- Get();
- if (IsNamedAssign()) {
- nameFound = true;
- IdentifierOrKeyword(out name);
+ lexer.NextToken();
+ if (
+#line 2635 "VBNET.ATG"
+IsNamedAssign()) {
+
+#line 2635 "VBNET.ATG"
+ nameFound = true;
+ IdentifierOrKeyword(
+#line 2636 "VBNET.ATG"
+out name);
if (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
Expect(10);
} else if (StartOf(29)) {
- if (nameFound) Error("no positional argument after named argument");
- } else SynErr(268);
- Expr(out expr);
+
+#line 2638 "VBNET.ATG"
+ if (nameFound) Error("no positional argument after named argument");
+ } else SynErr(271);
+ Expr(
+#line 2639 "VBNET.ATG"
+out expr);
+
+#line 2639 "VBNET.ATG"
if (expr != null) { if(name == "") positional.Add(expr);
else { named.Add(new NamedArgumentExpression(name, expr)); name = ""; }
}
-
+
}
}
Expect(26);
}
- void FormalParameter(out ParameterDeclarationExpression p) {
+ void FormalParameter(
+#line 2696 "VBNET.ATG"
+out ParameterDeclarationExpression p) {
+
+#line 2698 "VBNET.ATG"
AttributeSection section;
List attributes = new List();
TypeReference type = null;
@@ -3741,23 +5759,39 @@ partial class Parser : AbstractParser
Expression expr = null;
p = null;
ArrayList arrayModifiers = null;
-
+
while (la.kind == 28) {
- AttributeSection(out section);
- attributes.Add(section);
+ AttributeSection(
+#line 2707 "VBNET.ATG"
+out section);
+
+#line 2707 "VBNET.ATG"
+ attributes.Add(section);
}
while (StartOf(34)) {
- ParameterModifier(mod);
+ ParameterModifier(
+#line 2708 "VBNET.ATG"
+mod);
}
Identifier();
- string parameterName = t.val;
- if (IsDims()) {
- ArrayTypeModifiers(out arrayModifiers);
+
+#line 2709 "VBNET.ATG"
+ string parameterName = t.val;
+ if (
+#line 2710 "VBNET.ATG"
+IsDims()) {
+ ArrayTypeModifiers(
+#line 2710 "VBNET.ATG"
+out arrayModifiers);
}
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 2711 "VBNET.ATG"
+out type);
}
+
+#line 2713 "VBNET.ATG"
if(type != null) {
if (arrayModifiers != null) {
if (type.RankSpecifier != null) {
@@ -3769,245 +5803,391 @@ partial class Parser : AbstractParser
} else {
type = new TypeReference("System.Object", arrayModifiers == null ? null : (int[])arrayModifiers.ToArray(typeof(int)));
}
-
+
if (la.kind == 10) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 2725 "VBNET.ATG"
+out expr);
}
+
+#line 2727 "VBNET.ATG"
mod.Check();
p = new ParameterDeclarationExpression(type, parameterName, mod.Modifier, expr);
p.Attributes = attributes;
-
+
}
- void ParameterModifier(ParamModifierList m) {
+ void ParameterModifier(
+#line 3409 "VBNET.ATG"
+ParamModifierList m) {
if (la.kind == 59) {
- Get();
- m.Add(ParameterModifiers.In);
+ lexer.NextToken();
+
+#line 3410 "VBNET.ATG"
+ m.Add(ParameterModifiers.In);
} else if (la.kind == 56) {
- Get();
- m.Add(ParameterModifiers.Ref);
- } else if (la.kind == 160) {
- Get();
- m.Add(ParameterModifiers.Optional);
- } else if (la.kind == 167) {
- Get();
- m.Add(ParameterModifiers.Params);
- } else SynErr(269);
+ lexer.NextToken();
+
+#line 3411 "VBNET.ATG"
+ m.Add(ParameterModifiers.Ref);
+ } else if (la.kind == 161) {
+ lexer.NextToken();
+
+#line 3412 "VBNET.ATG"
+ m.Add(ParameterModifiers.Optional);
+ } else if (la.kind == 168) {
+ lexer.NextToken();
+
+#line 3413 "VBNET.ATG"
+ m.Add(ParameterModifiers.Params);
+ } else SynErr(272);
}
void Statement() {
+
+#line 2756 "VBNET.ATG"
Statement stmt = null;
Location startPos = la.Location;
string label = String.Empty;
-
-
+
+
if (la.kind == 1 || la.kind == 11) {
- } else if (IsLabel()) {
- LabelName(out label);
+ } else if (
+#line 2762 "VBNET.ATG"
+IsLabel()) {
+ LabelName(
+#line 2762 "VBNET.ATG"
+out label);
+
+#line 2764 "VBNET.ATG"
compilationUnit.AddChild(new LabelStatement(t.val));
-
+
Expect(11);
Statement();
} else if (StartOf(35)) {
- EmbeddedStatement(out stmt);
- compilationUnit.AddChild(stmt);
- } else SynErr(270);
+ EmbeddedStatement(
+#line 2767 "VBNET.ATG"
+out stmt);
+
+#line 2767 "VBNET.ATG"
+ compilationUnit.AddChild(stmt);
+ } else SynErr(273);
+
+#line 2770 "VBNET.ATG"
if (stmt != null) {
stmt.StartLocation = startPos;
stmt.EndLocation = t.Location;
}
-
+
}
- void LabelName(out string name) {
- name = String.Empty;
+ void LabelName(
+#line 3185 "VBNET.ATG"
+out string name) {
+#line 3187 "VBNET.ATG"
+ name = String.Empty;
+
if (StartOf(4)) {
Identifier();
- name = t.val;
+
+#line 3189 "VBNET.ATG"
+ name = t.val;
} else if (la.kind == 5) {
- Get();
- name = t.val;
- } else SynErr(271);
+ lexer.NextToken();
+
+#line 3190 "VBNET.ATG"
+ name = t.val;
+ } else SynErr(274);
}
- void EmbeddedStatement(out Statement statement) {
+ void EmbeddedStatement(
+#line 2809 "VBNET.ATG"
+out Statement statement) {
+
+#line 2811 "VBNET.ATG"
Statement embeddedStatement = null;
statement = null;
Expression expr = null;
string name = String.Empty;
List p = null;
-
+
if (la.kind == 107) {
- Get();
- ExitType exitType = ExitType.None;
+ lexer.NextToken();
+
+#line 2817 "VBNET.ATG"
+ ExitType exitType = ExitType.None;
switch (la.kind) {
- case 195: {
- Get();
- exitType = ExitType.Sub;
+ case 196: {
+ lexer.NextToken();
+
+#line 2819 "VBNET.ATG"
+ exitType = ExitType.Sub;
break;
}
case 114: {
- Get();
- exitType = ExitType.Function;
+ lexer.NextToken();
+
+#line 2821 "VBNET.ATG"
+ exitType = ExitType.Function;
break;
}
- case 171: {
- Get();
- exitType = ExitType.Property;
+ case 172: {
+ lexer.NextToken();
+
+#line 2823 "VBNET.ATG"
+ exitType = ExitType.Property;
break;
}
case 95: {
- Get();
- exitType = ExitType.Do;
+ lexer.NextToken();
+
+#line 2825 "VBNET.ATG"
+ exitType = ExitType.Do;
break;
}
case 111: {
- Get();
- exitType = ExitType.For;
+ lexer.NextToken();
+
+#line 2827 "VBNET.ATG"
+ exitType = ExitType.For;
break;
}
- case 203: {
- Get();
- exitType = ExitType.Try;
+ case 204: {
+ lexer.NextToken();
+
+#line 2829 "VBNET.ATG"
+ exitType = ExitType.Try;
break;
}
- case 216: {
- Get();
- exitType = ExitType.While;
+ case 217: {
+ lexer.NextToken();
+
+#line 2831 "VBNET.ATG"
+ exitType = ExitType.While;
break;
}
- case 182: {
- Get();
- exitType = ExitType.Select;
+ case 183: {
+ lexer.NextToken();
+
+#line 2833 "VBNET.ATG"
+ exitType = ExitType.Select;
break;
}
- default: SynErr(272); break;
+ default: SynErr(275); break;
}
- statement = new ExitStatement(exitType);
- } else if (la.kind == 203) {
- TryStatement(out statement);
+
+#line 2835 "VBNET.ATG"
+ statement = new ExitStatement(exitType);
+ } else if (la.kind == 204) {
+ TryStatement(
+#line 2836 "VBNET.ATG"
+out statement);
} else if (la.kind == 76) {
- Get();
- ContinueType continueType = ContinueType.None;
- if (la.kind == 95 || la.kind == 111 || la.kind == 216) {
+ lexer.NextToken();
+
+#line 2837 "VBNET.ATG"
+ ContinueType continueType = ContinueType.None;
+ if (la.kind == 95 || la.kind == 111 || la.kind == 217) {
if (la.kind == 95) {
- Get();
- continueType = ContinueType.Do;
+ lexer.NextToken();
+
+#line 2837 "VBNET.ATG"
+ continueType = ContinueType.Do;
} else if (la.kind == 111) {
- Get();
- continueType = ContinueType.For;
+ lexer.NextToken();
+
+#line 2837 "VBNET.ATG"
+ continueType = ContinueType.For;
} else {
- Get();
- continueType = ContinueType.While;
+ lexer.NextToken();
+
+#line 2837 "VBNET.ATG"
+ continueType = ContinueType.While;
}
}
- statement = new ContinueStatement(continueType);
- } else if (la.kind == 200) {
- Get();
+
+#line 2837 "VBNET.ATG"
+ statement = new ContinueStatement(continueType);
+ } else if (la.kind == 201) {
+ lexer.NextToken();
if (StartOf(29)) {
- Expr(out expr);
+ Expr(
+#line 2839 "VBNET.ATG"
+out expr);
}
- statement = new ThrowStatement(expr);
- } else if (la.kind == 180) {
- Get();
+
+#line 2839 "VBNET.ATG"
+ statement = new ThrowStatement(expr);
+ } else if (la.kind == 181) {
+ lexer.NextToken();
if (StartOf(29)) {
- Expr(out expr);
- }
- statement = new ReturnStatement(expr);
- } else if (la.kind == 196) {
- Get();
- Expr(out expr);
+ Expr(
+#line 2841 "VBNET.ATG"
+out expr);
+ }
+
+#line 2841 "VBNET.ATG"
+ statement = new ReturnStatement(expr);
+ } else if (la.kind == 197) {
+ lexer.NextToken();
+ Expr(
+#line 2843 "VBNET.ATG"
+out expr);
EndOfStmt();
- Block(out embeddedStatement);
+ Block(
+#line 2843 "VBNET.ATG"
+out embeddedStatement);
Expect(100);
- Expect(196);
- statement = new LockStatement(expr, embeddedStatement);
- } else if (la.kind == 174) {
- Get();
+ Expect(197);
+
+#line 2844 "VBNET.ATG"
+ statement = new LockStatement(expr, embeddedStatement);
+ } else if (la.kind == 175) {
+ lexer.NextToken();
Identifier();
- name = t.val;
+
+#line 2846 "VBNET.ATG"
+ name = t.val;
if (la.kind == 25) {
- Get();
+ lexer.NextToken();
if (StartOf(36)) {
- ArgumentList(out p);
+ ArgumentList(
+#line 2847 "VBNET.ATG"
+out p);
}
Expect(26);
}
- statement = new RaiseEventStatement(name, p);
- } else if (la.kind == 218) {
- WithStatement(out statement);
+#line 2849 "VBNET.ATG"
+ statement = new RaiseEventStatement(name, p);
+
+ } else if (la.kind == 219) {
+ WithStatement(
+#line 2852 "VBNET.ATG"
+out statement);
} else if (la.kind == 43) {
- Get();
- Expression handlerExpr = null;
- Expr(out expr);
+ lexer.NextToken();
+
+#line 2854 "VBNET.ATG"
+ Expression handlerExpr = null;
+ Expr(
+#line 2855 "VBNET.ATG"
+out expr);
Expect(12);
- Expr(out handlerExpr);
+ Expr(
+#line 2855 "VBNET.ATG"
+out handlerExpr);
+
+#line 2857 "VBNET.ATG"
statement = new AddHandlerStatement(expr, handlerExpr);
+
+ } else if (la.kind == 179) {
+ lexer.NextToken();
- } else if (la.kind == 178) {
- Get();
- Expression handlerExpr = null;
- Expr(out expr);
+#line 2860 "VBNET.ATG"
+ Expression handlerExpr = null;
+ Expr(
+#line 2861 "VBNET.ATG"
+out expr);
Expect(12);
- Expr(out handlerExpr);
- statement = new RemoveHandlerStatement(expr, handlerExpr);
+ Expr(
+#line 2861 "VBNET.ATG"
+out handlerExpr);
- } else if (la.kind == 216) {
- Get();
- Expr(out expr);
+#line 2863 "VBNET.ATG"
+ statement = new RemoveHandlerStatement(expr, handlerExpr);
+
+ } else if (la.kind == 217) {
+ lexer.NextToken();
+ Expr(
+#line 2866 "VBNET.ATG"
+out expr);
EndOfStmt();
- Block(out embeddedStatement);
+ Block(
+#line 2867 "VBNET.ATG"
+out embeddedStatement);
Expect(100);
- Expect(216);
- statement = new DoLoopStatement(expr, embeddedStatement, ConditionType.While, ConditionPosition.Start);
+ Expect(217);
+#line 2869 "VBNET.ATG"
+ statement = new DoLoopStatement(expr, embeddedStatement, ConditionType.While, ConditionPosition.Start);
+
} else if (la.kind == 95) {
- Get();
- ConditionType conditionType = ConditionType.None;
+ lexer.NextToken();
- if (la.kind == 209 || la.kind == 216) {
- WhileOrUntil(out conditionType);
- Expr(out expr);
+#line 2874 "VBNET.ATG"
+ ConditionType conditionType = ConditionType.None;
+
+ if (la.kind == 210 || la.kind == 217) {
+ WhileOrUntil(
+#line 2877 "VBNET.ATG"
+out conditionType);
+ Expr(
+#line 2877 "VBNET.ATG"
+out expr);
EndOfStmt();
- Block(out embeddedStatement);
- Expect(138);
+ Block(
+#line 2878 "VBNET.ATG"
+out embeddedStatement);
+ Expect(139);
+
+#line 2881 "VBNET.ATG"
statement = new DoLoopStatement(expr,
embeddedStatement,
conditionType == ConditionType.While ? ConditionType.DoWhile : conditionType,
ConditionPosition.Start);
-
+
} else if (la.kind == 1 || la.kind == 11) {
EndOfStmt();
- Block(out embeddedStatement);
- Expect(138);
- if (la.kind == 209 || la.kind == 216) {
- WhileOrUntil(out conditionType);
- Expr(out expr);
+ Block(
+#line 2888 "VBNET.ATG"
+out embeddedStatement);
+ Expect(139);
+ if (la.kind == 210 || la.kind == 217) {
+ WhileOrUntil(
+#line 2889 "VBNET.ATG"
+out conditionType);
+ Expr(
+#line 2889 "VBNET.ATG"
+out expr);
}
- statement = new DoLoopStatement(expr, embeddedStatement, conditionType, ConditionPosition.End);
- } else SynErr(273);
+#line 2891 "VBNET.ATG"
+ statement = new DoLoopStatement(expr, embeddedStatement, conditionType, ConditionPosition.End);
+
+ } else SynErr(276);
} else if (la.kind == 111) {
- Get();
+ lexer.NextToken();
+
+#line 2896 "VBNET.ATG"
Expression group = null;
TypeReference typeReference;
string typeName;
Location startLocation = t.Location;
-
+
if (la.kind == 97) {
- Get();
- LoopControlVariable(out typeReference, out typeName);
+ lexer.NextToken();
+ LoopControlVariable(
+#line 2903 "VBNET.ATG"
+out typeReference, out typeName);
Expect(125);
- Expr(out group);
+ Expr(
+#line 2904 "VBNET.ATG"
+out group);
EndOfStmt();
- Block(out embeddedStatement);
- Expect(149);
+ Block(
+#line 2905 "VBNET.ATG"
+out embeddedStatement);
+ Expect(150);
if (StartOf(29)) {
- Expr(out expr);
+ Expr(
+#line 2906 "VBNET.ATG"
+out expr);
}
+
+#line 2908 "VBNET.ATG"
statement = new ForeachStatement(typeReference,
typeName,
group,
@@ -4015,44 +6195,72 @@ partial class Parser : AbstractParser
expr);
statement.StartLocation = startLocation;
statement.EndLocation = t.EndLocation;
-
-
+
+
} else if (StartOf(37)) {
+
+#line 2919 "VBNET.ATG"
Expression start = null;
Expression end = null;
Expression step = null;
Expression variableExpr = null;
Expression nextExpr = null;
List nextExpressions = null;
-
- if (IsLoopVariableDeclaration()) {
- LoopControlVariable(out typeReference, out typeName);
+
+ if (
+#line 2926 "VBNET.ATG"
+IsLoopVariableDeclaration()) {
+ LoopControlVariable(
+#line 2927 "VBNET.ATG"
+out typeReference, out typeName);
} else {
- typeReference = null; typeName = null;
- SimpleExpr(out variableExpr);
+
+#line 2929 "VBNET.ATG"
+ typeReference = null; typeName = null;
+ SimpleExpr(
+#line 2930 "VBNET.ATG"
+out variableExpr);
}
Expect(10);
- Expr(out start);
- Expect(201);
- Expr(out end);
- if (la.kind == 190) {
- Get();
- Expr(out step);
+ Expr(
+#line 2932 "VBNET.ATG"
+out start);
+ Expect(202);
+ Expr(
+#line 2932 "VBNET.ATG"
+out end);
+ if (la.kind == 191) {
+ lexer.NextToken();
+ Expr(
+#line 2932 "VBNET.ATG"
+out step);
}
EndOfStmt();
- Block(out embeddedStatement);
- Expect(149);
+ Block(
+#line 2933 "VBNET.ATG"
+out embeddedStatement);
+ Expect(150);
if (StartOf(29)) {
- Expr(out nextExpr);
+ Expr(
+#line 2936 "VBNET.ATG"
+out nextExpr);
+
+#line 2938 "VBNET.ATG"
nextExpressions = new List();
nextExpressions.Add(nextExpr);
-
+
while (la.kind == 12) {
- Get();
- Expr(out nextExpr);
- nextExpressions.Add(nextExpr);
+ lexer.NextToken();
+ Expr(
+#line 2941 "VBNET.ATG"
+out nextExpr);
+
+#line 2941 "VBNET.ATG"
+ nextExpressions.Add(nextExpr);
}
}
+
+#line 2944 "VBNET.ATG"
statement = new ForNextStatement {
TypeReference = typeReference,
VariableName = typeName,
@@ -4063,300 +6271,516 @@ partial class Parser : AbstractParser
EmbeddedStatement = embeddedStatement,
NextExpressions = nextExpressions
};
-
- } else SynErr(274);
+
+ } else SynErr(277);
} else if (la.kind == 105) {
- Get();
- Expr(out expr);
- statement = new ErrorStatement(expr);
- } else if (la.kind == 176) {
- Get();
- bool isPreserve = false;
- if (la.kind == 169) {
- Get();
- isPreserve = true;
- }
- ReDimClause(out expr);
+ lexer.NextToken();
+ Expr(
+#line 2957 "VBNET.ATG"
+out expr);
+
+#line 2957 "VBNET.ATG"
+ statement = new ErrorStatement(expr);
+ } else if (la.kind == 177) {
+ lexer.NextToken();
+
+#line 2959 "VBNET.ATG"
+ bool isPreserve = false;
+ if (la.kind == 170) {
+ lexer.NextToken();
+
+#line 2959 "VBNET.ATG"
+ isPreserve = true;
+ }
+ ReDimClause(
+#line 2960 "VBNET.ATG"
+out expr);
+
+#line 2962 "VBNET.ATG"
ReDimStatement reDimStatement = new ReDimStatement(isPreserve);
statement = reDimStatement;
SafeAdd(reDimStatement, reDimStatement.ReDimClauses, expr as InvocationExpression);
-
+
while (la.kind == 12) {
- Get();
- ReDimClause(out expr);
- SafeAdd(reDimStatement, reDimStatement.ReDimClauses, expr as InvocationExpression);
+ lexer.NextToken();
+ ReDimClause(
+#line 2966 "VBNET.ATG"
+out expr);
+
+#line 2967 "VBNET.ATG"
+ SafeAdd(reDimStatement, reDimStatement.ReDimClauses, expr as InvocationExpression);
}
} else if (la.kind == 104) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 2971 "VBNET.ATG"
+out expr);
+
+#line 2973 "VBNET.ATG"
EraseStatement eraseStatement = new EraseStatement();
if (expr != null) { SafeAdd(eraseStatement, eraseStatement.Expressions, expr);}
-
+
while (la.kind == 12) {
- Get();
- Expr(out expr);
+ lexer.NextToken();
+ Expr(
+#line 2976 "VBNET.ATG"
+out expr);
+
+#line 2976 "VBNET.ATG"
if (expr != null) { SafeAdd(eraseStatement, eraseStatement.Expressions, expr); }
}
- statement = eraseStatement;
- } else if (la.kind == 191) {
- Get();
- statement = new StopStatement();
- } else if (la.kind == Tokens.If) {
+
+#line 2977 "VBNET.ATG"
+ statement = eraseStatement;
+ } else if (la.kind == 192) {
+ lexer.NextToken();
+
+#line 2979 "VBNET.ATG"
+ statement = new StopStatement();
+ } else if (
+#line 2981 "VBNET.ATG"
+la.kind == Tokens.If) {
Expect(122);
- Location ifStartLocation = t.Location;
- Expr(out expr);
- if (la.kind == 199) {
- Get();
+
+#line 2982 "VBNET.ATG"
+ Location ifStartLocation = t.Location;
+ Expr(
+#line 2982 "VBNET.ATG"
+out expr);
+ if (la.kind == 200) {
+ lexer.NextToken();
}
if (la.kind == 1 || la.kind == 11) {
EndOfStmt();
- Block(out embeddedStatement);
+ Block(
+#line 2985 "VBNET.ATG"
+out embeddedStatement);
+
+#line 2987 "VBNET.ATG"
IfElseStatement ifStatement = new IfElseStatement(expr, embeddedStatement);
ifStatement.StartLocation = ifStartLocation;
Location elseIfStart;
-
- while (la.kind == 98 || la.kind == 99) {
- if (IsElseIf()) {
+
+ while (la.kind == 99 ||
+#line 2993 "VBNET.ATG"
+IsElseIf()) {
+ if (
+#line 2993 "VBNET.ATG"
+IsElseIf()) {
Expect(98);
- elseIfStart = t.Location;
+
+#line 2993 "VBNET.ATG"
+ elseIfStart = t.Location;
Expect(122);
} else {
- Get();
- elseIfStart = t.Location;
+ lexer.NextToken();
+
+#line 2994 "VBNET.ATG"
+ elseIfStart = t.Location;
}
- Expression condition = null; Statement block = null;
- Expr(out condition);
- if (la.kind == 199) {
- Get();
+
+#line 2996 "VBNET.ATG"
+ Expression condition = null; Statement block = null;
+ Expr(
+#line 2997 "VBNET.ATG"
+out condition);
+ if (la.kind == 200) {
+ lexer.NextToken();
}
EndOfStmt();
- Block(out block);
+ Block(
+#line 2998 "VBNET.ATG"
+out block);
+
+#line 3000 "VBNET.ATG"
ElseIfSection elseIfSection = new ElseIfSection(condition, block);
elseIfSection.StartLocation = elseIfStart;
elseIfSection.EndLocation = t.Location;
elseIfSection.Parent = ifStatement;
ifStatement.ElseIfSections.Add(elseIfSection);
-
+
}
if (la.kind == 98) {
- Get();
+ lexer.NextToken();
if (la.kind == 1 || la.kind == 11) {
EndOfStmt();
}
- Block(out embeddedStatement);
- ifStatement.FalseStatement.Add(embeddedStatement);
+ Block(
+#line 3009 "VBNET.ATG"
+out embeddedStatement);
+#line 3011 "VBNET.ATG"
+ ifStatement.FalseStatement.Add(embeddedStatement);
+
}
Expect(100);
Expect(122);
+
+#line 3015 "VBNET.ATG"
ifStatement.EndLocation = t.Location;
statement = ifStatement;
-
+
} else if (StartOf(38)) {
+
+#line 3020 "VBNET.ATG"
IfElseStatement ifStatement = new IfElseStatement(expr);
ifStatement.StartLocation = ifStartLocation;
-
- SingleLineStatementList(ifStatement.TrueStatement);
+
+ SingleLineStatementList(
+#line 3023 "VBNET.ATG"
+ifStatement.TrueStatement);
if (la.kind == 98) {
- Get();
+ lexer.NextToken();
if (StartOf(38)) {
- SingleLineStatementList(ifStatement.FalseStatement);
+ SingleLineStatementList(
+#line 3026 "VBNET.ATG"
+ifStatement.FalseStatement);
}
}
- ifStatement.EndLocation = t.Location; statement = ifStatement;
- } else SynErr(275);
- } else if (la.kind == 182) {
- Get();
+
+#line 3028 "VBNET.ATG"
+ ifStatement.EndLocation = t.Location; statement = ifStatement;
+ } else SynErr(278);
+ } else if (la.kind == 183) {
+ lexer.NextToken();
if (la.kind == 61) {
- Get();
+ lexer.NextToken();
}
- Expr(out expr);
+ Expr(
+#line 3031 "VBNET.ATG"
+out expr);
EndOfStmt();
+
+#line 3032 "VBNET.ATG"
List selectSections = new List();
Statement block = null;
-
+
while (la.kind == 61) {
- List caseClauses = null; Location caseLocation = la.Location;
- Get();
- CaseClauses(out caseClauses);
- if (IsNotStatementSeparator()) {
- Expect(11);
+
+#line 3036 "VBNET.ATG"
+ List caseClauses = null; Location caseLocation = la.Location;
+ lexer.NextToken();
+ CaseClauses(
+#line 3037 "VBNET.ATG"
+out caseClauses);
+ if (
+#line 3037 "VBNET.ATG"
+IsNotStatementSeparator()) {
+ lexer.NextToken();
}
EndOfStmt();
+
+#line 3039 "VBNET.ATG"
SwitchSection selectSection = new SwitchSection(caseClauses);
selectSection.StartLocation = caseLocation;
+
+ Block(
+#line 3042 "VBNET.ATG"
+out block);
- Block(out block);
+#line 3044 "VBNET.ATG"
selectSection.Children = block.Children;
selectSection.EndLocation = t.EndLocation;
selectSections.Add(selectSection);
-
+
}
- statement = new SwitchStatement(expr, selectSections);
+#line 3050 "VBNET.ATG"
+ statement = new SwitchStatement(expr, selectSections);
+
Expect(100);
- Expect(182);
- } else if (la.kind == 157) {
- OnErrorStatement onErrorStatement = null;
- OnErrorStatement(out onErrorStatement);
- statement = onErrorStatement;
+ Expect(183);
+ } else if (la.kind == 158) {
+
+#line 3053 "VBNET.ATG"
+ OnErrorStatement onErrorStatement = null;
+ OnErrorStatement(
+#line 3054 "VBNET.ATG"
+out onErrorStatement);
+
+#line 3054 "VBNET.ATG"
+ statement = onErrorStatement;
} else if (la.kind == 119) {
- GotoStatement goToStatement = null;
- GotoStatement(out goToStatement);
- statement = goToStatement;
- } else if (la.kind == 179) {
- ResumeStatement resumeStatement = null;
- ResumeStatement(out resumeStatement);
- statement = resumeStatement;
+
+#line 3055 "VBNET.ATG"
+ GotoStatement goToStatement = null;
+ GotoStatement(
+#line 3056 "VBNET.ATG"
+out goToStatement);
+
+#line 3056 "VBNET.ATG"
+ statement = goToStatement;
+ } else if (la.kind == 180) {
+
+#line 3057 "VBNET.ATG"
+ ResumeStatement resumeStatement = null;
+ ResumeStatement(
+#line 3058 "VBNET.ATG"
+out resumeStatement);
+
+#line 3058 "VBNET.ATG"
+ statement = resumeStatement;
} else if (StartOf(37)) {
+
+#line 3061 "VBNET.ATG"
Expression val = null;
AssignmentOperatorType op;
-
+
bool mustBeAssignment = la.kind == Tokens.Plus || la.kind == Tokens.Minus ||
la.kind == Tokens.Not || la.kind == Tokens.Times;
-
- SimpleExpr(out expr);
+
+ SimpleExpr(
+#line 3067 "VBNET.ATG"
+out expr);
if (StartOf(39)) {
- AssignmentOperator(out op);
- Expr(out val);
- expr = new AssignmentExpression(expr, op, val);
+ AssignmentOperator(
+#line 3069 "VBNET.ATG"
+out op);
+ Expr(
+#line 3069 "VBNET.ATG"
+out val);
+
+#line 3069 "VBNET.ATG"
+ expr = new AssignmentExpression(expr, op, val);
} else if (la.kind == 1 || la.kind == 11 || la.kind == 98) {
- if (mustBeAssignment) Error("error in assignment.");
- } else SynErr(276);
+
+#line 3070 "VBNET.ATG"
+ if (mustBeAssignment) Error("error in assignment.");
+ } else SynErr(279);
+
+#line 3073 "VBNET.ATG"
+ // a field reference expression that stands alone is a
+ // invocation expression without parantheses and arguments
if(expr is MemberReferenceExpression || expr is IdentifierExpression) {
- expr = new InvocationExpression(expr);
+ expr = new InvocationExpression(expr);
}
statement = new ExpressionStatement(expr);
-
+
} else if (la.kind == 60) {
- Get();
- SimpleExpr(out expr);
- statement = new ExpressionStatement(expr);
- } else if (la.kind == 211) {
- Get();
- Statement block;
- if (Peek(1).kind == Tokens.As) {
- LocalVariableDeclaration resourceAquisition = new LocalVariableDeclaration(Modifiers.None);
- VariableDeclarator(resourceAquisition.Variables);
+ lexer.NextToken();
+ SimpleExpr(
+#line 3080 "VBNET.ATG"
+out expr);
+
+#line 3080 "VBNET.ATG"
+ statement = new ExpressionStatement(expr);
+ } else if (la.kind == 212) {
+ lexer.NextToken();
+
+#line 3082 "VBNET.ATG"
+ Statement block;
+ if (
+#line 3083 "VBNET.ATG"
+Peek(1).kind == Tokens.As) {
+
+#line 3084 "VBNET.ATG"
+ LocalVariableDeclaration resourceAquisition = new LocalVariableDeclaration(Modifiers.None);
+ VariableDeclarator(
+#line 3085 "VBNET.ATG"
+resourceAquisition.Variables);
while (la.kind == 12) {
- Get();
- VariableDeclarator(resourceAquisition.Variables);
+ lexer.NextToken();
+ VariableDeclarator(
+#line 3087 "VBNET.ATG"
+resourceAquisition.Variables);
}
- Block(out block);
- statement = new UsingStatement(resourceAquisition, block);
+ Block(
+#line 3089 "VBNET.ATG"
+out block);
+#line 3091 "VBNET.ATG"
+ statement = new UsingStatement(resourceAquisition, block);
+
} else if (StartOf(29)) {
- Expr(out expr);
- Block(out block);
- statement = new UsingStatement(new ExpressionStatement(expr), block);
- } else SynErr(277);
+ Expr(
+#line 3093 "VBNET.ATG"
+out expr);
+ Block(
+#line 3094 "VBNET.ATG"
+out block);
+
+#line 3095 "VBNET.ATG"
+ statement = new UsingStatement(new ExpressionStatement(expr), block);
+ } else SynErr(280);
Expect(100);
- Expect(211);
+ Expect(212);
} else if (StartOf(40)) {
- LocalDeclarationStatement(out statement);
- } else SynErr(278);
+ LocalDeclarationStatement(
+#line 3098 "VBNET.ATG"
+out statement);
+ } else SynErr(281);
}
- void LocalDeclarationStatement(out Statement statement) {
+ void LocalDeclarationStatement(
+#line 2778 "VBNET.ATG"
+out Statement statement) {
+
+#line 2780 "VBNET.ATG"
ModifierList m = new ModifierList();
LocalVariableDeclaration localVariableDeclaration;
bool dimfound = false;
-
- while (la.kind == 75 || la.kind == 92 || la.kind == 189) {
+
+ while (la.kind == 75 || la.kind == 92 || la.kind == 190) {
if (la.kind == 75) {
- Get();
- m.Add(Modifiers.Const, t.Location);
- } else if (la.kind == 189) {
- Get();
- m.Add(Modifiers.Static, t.Location);
+ lexer.NextToken();
+
+#line 2786 "VBNET.ATG"
+ m.Add(Modifiers.Const, t.Location);
+ } else if (la.kind == 190) {
+ lexer.NextToken();
+
+#line 2787 "VBNET.ATG"
+ m.Add(Modifiers.Static, t.Location);
} else {
- Get();
- dimfound = true;
+ lexer.NextToken();
+
+#line 2788 "VBNET.ATG"
+ dimfound = true;
}
}
+
+#line 2791 "VBNET.ATG"
if(dimfound && (m.Modifier & Modifiers.Const) != 0) {
Error("Dim is not allowed on constants.");
}
-
+
if(m.isNone && dimfound == false) {
Error("Const, Dim or Static expected");
}
-
+
localVariableDeclaration = new LocalVariableDeclaration(m.Modifier);
localVariableDeclaration.StartLocation = t.Location;
-
- VariableDeclarator(localVariableDeclaration.Variables);
+
+ VariableDeclarator(
+#line 2802 "VBNET.ATG"
+localVariableDeclaration.Variables);
while (la.kind == 12) {
- Get();
- VariableDeclarator(localVariableDeclaration.Variables);
+ lexer.NextToken();
+ VariableDeclarator(
+#line 2803 "VBNET.ATG"
+localVariableDeclaration.Variables);
}
- statement = localVariableDeclaration;
+#line 2805 "VBNET.ATG"
+ statement = localVariableDeclaration;
+
}
- void TryStatement(out Statement tryStatement) {
- Statement blockStmt = null, finallyStmt = null;List catchClauses = null;
+ void TryStatement(
+#line 3299 "VBNET.ATG"
+out Statement tryStatement) {
- Expect(203);
+#line 3301 "VBNET.ATG"
+ Statement blockStmt = null, finallyStmt = null;List catchClauses = null;
+
+ Expect(204);
EndOfStmt();
- Block(out blockStmt);
+ Block(
+#line 3304 "VBNET.ATG"
+out blockStmt);
if (la.kind == 62 || la.kind == 100 || la.kind == 110) {
- CatchClauses(out catchClauses);
+ CatchClauses(
+#line 3305 "VBNET.ATG"
+out catchClauses);
}
if (la.kind == 110) {
- Get();
+ lexer.NextToken();
EndOfStmt();
- Block(out finallyStmt);
+ Block(
+#line 3306 "VBNET.ATG"
+out finallyStmt);
}
Expect(100);
- Expect(203);
- tryStatement = new TryCatchStatement(blockStmt, catchClauses, finallyStmt);
+ Expect(204);
+#line 3309 "VBNET.ATG"
+ tryStatement = new TryCatchStatement(blockStmt, catchClauses, finallyStmt);
+
}
- void WithStatement(out Statement withStatement) {
+ void WithStatement(
+#line 3279 "VBNET.ATG"
+out Statement withStatement) {
+
+#line 3281 "VBNET.ATG"
Statement blockStmt = null;
Expression expr = null;
-
- Expect(218);
- Location start = t.Location;
- Expr(out expr);
+
+ Expect(219);
+
+#line 3284 "VBNET.ATG"
+ Location start = t.Location;
+ Expr(
+#line 3285 "VBNET.ATG"
+out expr);
EndOfStmt();
+
+#line 3287 "VBNET.ATG"
withStatement = new WithStatement(expr);
withStatement.StartLocation = start;
+
+ Block(
+#line 3290 "VBNET.ATG"
+out blockStmt);
- Block(out blockStmt);
+#line 3292 "VBNET.ATG"
((WithStatement)withStatement).Body = (BlockStatement)blockStmt;
-
+
Expect(100);
- Expect(218);
- withStatement.EndLocation = t.Location;
+ Expect(219);
+
+#line 3295 "VBNET.ATG"
+ withStatement.EndLocation = t.Location;
}
- void WhileOrUntil(out ConditionType conditionType) {
- conditionType = ConditionType.None;
- if (la.kind == 216) {
- Get();
- conditionType = ConditionType.While;
- } else if (la.kind == 209) {
- Get();
- conditionType = ConditionType.Until;
- } else SynErr(279);
+ void WhileOrUntil(
+#line 3272 "VBNET.ATG"
+out ConditionType conditionType) {
+
+#line 3273 "VBNET.ATG"
+ conditionType = ConditionType.None;
+ if (la.kind == 217) {
+ lexer.NextToken();
+
+#line 3274 "VBNET.ATG"
+ conditionType = ConditionType.While;
+ } else if (la.kind == 210) {
+ lexer.NextToken();
+
+#line 3275 "VBNET.ATG"
+ conditionType = ConditionType.Until;
+ } else SynErr(282);
}
- void LoopControlVariable(out TypeReference type, out string name) {
+ void LoopControlVariable(
+#line 3115 "VBNET.ATG"
+out TypeReference type, out string name) {
+
+#line 3116 "VBNET.ATG"
ArrayList arrayModifiers = null;
type = null;
-
- Qualident(out name);
- if (IsDims()) {
- ArrayTypeModifiers(out arrayModifiers);
+
+ Qualident(
+#line 3120 "VBNET.ATG"
+out name);
+ if (
+#line 3121 "VBNET.ATG"
+IsDims()) {
+ ArrayTypeModifiers(
+#line 3121 "VBNET.ATG"
+out arrayModifiers);
}
if (la.kind == 50) {
- Get();
- TypeName(out type);
- if (name.IndexOf('.') > 0) { Error("No type def for 'for each' member indexer allowed."); }
+ lexer.NextToken();
+ TypeName(
+#line 3122 "VBNET.ATG"
+out type);
+
+#line 3122 "VBNET.ATG"
+ if (name.IndexOf('.') > 0) { Error("No type def for 'for each' member indexer allowed."); }
}
+
+#line 3124 "VBNET.ATG"
if (type != null) {
if(type.RankSpecifier != null && arrayModifiers != null) {
Error("array rank only allowed one time");
@@ -4364,71 +6788,117 @@ partial class Parser : AbstractParser
type.RankSpecifier = (int[])arrayModifiers.ToArray(typeof(int));
}
}
-
+
}
- void ReDimClause(out Expression expr) {
- SimpleNonInvocationExpression(out expr);
- ReDimClauseInternal(ref expr);
+ void ReDimClause(
+#line 3194 "VBNET.ATG"
+out Expression expr) {
+ SimpleNonInvocationExpression(
+#line 3196 "VBNET.ATG"
+out expr);
+ ReDimClauseInternal(
+#line 3197 "VBNET.ATG"
+ref expr);
}
- void SingleLineStatementList(List list) {
- Statement embeddedStatement = null;
+ void SingleLineStatementList(
+#line 3101 "VBNET.ATG"
+List list) {
+
+#line 3102 "VBNET.ATG"
+ Statement embeddedStatement = null;
if (la.kind == 100) {
- Get();
- embeddedStatement = new EndStatement();
+ lexer.NextToken();
+
+#line 3104 "VBNET.ATG"
+ embeddedStatement = new EndStatement();
} else if (StartOf(35)) {
- EmbeddedStatement(out embeddedStatement);
- } else SynErr(280);
- if (embeddedStatement != null) list.Add(embeddedStatement);
+ EmbeddedStatement(
+#line 3105 "VBNET.ATG"
+out embeddedStatement);
+ } else SynErr(283);
+
+#line 3106 "VBNET.ATG"
+ if (embeddedStatement != null) list.Add(embeddedStatement);
while (la.kind == 11) {
- Get();
+ lexer.NextToken();
while (la.kind == 11) {
- Get();
+ lexer.NextToken();
}
if (la.kind == 100) {
- Get();
- embeddedStatement = new EndStatement();
+ lexer.NextToken();
+
+#line 3108 "VBNET.ATG"
+ embeddedStatement = new EndStatement();
} else if (StartOf(35)) {
- EmbeddedStatement(out embeddedStatement);
- } else SynErr(281);
- if (embeddedStatement != null) list.Add(embeddedStatement);
+ EmbeddedStatement(
+#line 3109 "VBNET.ATG"
+out embeddedStatement);
+ } else SynErr(284);
+
+#line 3110 "VBNET.ATG"
+ if (embeddedStatement != null) list.Add(embeddedStatement);
}
}
- void CaseClauses(out List caseClauses) {
+ void CaseClauses(
+#line 3232 "VBNET.ATG"
+out List caseClauses) {
+
+#line 3234 "VBNET.ATG"
caseClauses = new List();
CaseLabel caseClause = null;
+
+ CaseClause(
+#line 3237 "VBNET.ATG"
+out caseClause);
- CaseClause(out caseClause);
- if (caseClause != null) { caseClauses.Add(caseClause); }
+#line 3237 "VBNET.ATG"
+ if (caseClause != null) { caseClauses.Add(caseClause); }
while (la.kind == 12) {
- Get();
- CaseClause(out caseClause);
- if (caseClause != null) { caseClauses.Add(caseClause); }
+ lexer.NextToken();
+ CaseClause(
+#line 3238 "VBNET.ATG"
+out caseClause);
+
+#line 3238 "VBNET.ATG"
+ if (caseClause != null) { caseClauses.Add(caseClause); }
}
}
- void OnErrorStatement(out OnErrorStatement stmt) {
+ void OnErrorStatement(
+#line 3135 "VBNET.ATG"
+out OnErrorStatement stmt) {
+
+#line 3137 "VBNET.ATG"
stmt = null;
GotoStatement goToStatement = null;
-
- Expect(157);
+
+ Expect(158);
Expect(105);
- if (IsNegativeLabelName()) {
+ if (
+#line 3143 "VBNET.ATG"
+IsNegativeLabelName()) {
Expect(119);
Expect(18);
Expect(5);
+
+#line 3145 "VBNET.ATG"
long intLabel = Int64.Parse(t.val);
if(intLabel != 1) {
Error("invalid label in on error statement.");
}
stmt = new OnErrorStatement(new GotoStatement((intLabel * -1).ToString()));
-
+
} else if (la.kind == 119) {
- GotoStatement(out goToStatement);
- string val = goToStatement.Label;
+ GotoStatement(
+#line 3151 "VBNET.ATG"
+out goToStatement);
+#line 3153 "VBNET.ATG"
+ string val = goToStatement.Label;
+
// if value is numeric, make sure that is 0
try {
long intLabel = Int64.Parse(val);
@@ -4438,55 +6908,93 @@ partial class Parser : AbstractParser
} catch {
}
stmt = new OnErrorStatement(goToStatement);
+
+ } else if (la.kind == 180) {
+ lexer.NextToken();
+ Expect(150);
- } else if (la.kind == 179) {
- Get();
- Expect(149);
+#line 3167 "VBNET.ATG"
stmt = new OnErrorStatement(new ResumeStatement(true));
-
- } else SynErr(282);
+
+ } else SynErr(285);
}
- void GotoStatement(out GotoStatement goToStatement) {
- string label = String.Empty;
+ void GotoStatement(
+#line 3173 "VBNET.ATG"
+out GotoStatement goToStatement) {
+#line 3175 "VBNET.ATG"
+ string label = String.Empty;
+
Expect(119);
- LabelName(out label);
- goToStatement = new GotoStatement(label);
+ LabelName(
+#line 3178 "VBNET.ATG"
+out label);
+#line 3180 "VBNET.ATG"
+ goToStatement = new GotoStatement(label);
+
}
- void ResumeStatement(out ResumeStatement resumeStatement) {
+ void ResumeStatement(
+#line 3221 "VBNET.ATG"
+out ResumeStatement resumeStatement) {
+
+#line 3223 "VBNET.ATG"
resumeStatement = null;
string label = String.Empty;
-
- if (IsResumeNext()) {
- Expect(179);
- Expect(149);
- resumeStatement = new ResumeStatement(true);
- } else if (la.kind == 179) {
- Get();
+
+ if (
+#line 3226 "VBNET.ATG"
+IsResumeNext()) {
+ Expect(180);
+ Expect(150);
+
+#line 3227 "VBNET.ATG"
+ resumeStatement = new ResumeStatement(true);
+ } else if (la.kind == 180) {
+ lexer.NextToken();
if (StartOf(41)) {
- LabelName(out label);
+ LabelName(
+#line 3228 "VBNET.ATG"
+out label);
}
- resumeStatement = new ResumeStatement(label);
- } else SynErr(283);
+
+#line 3228 "VBNET.ATG"
+ resumeStatement = new ResumeStatement(label);
+ } else SynErr(286);
}
- void ReDimClauseInternal(ref Expression expr) {
- List arguments; bool canBeNormal; bool canBeRedim; string name;
- while (la.kind == 16 || la.kind == 25) {
+ void ReDimClauseInternal(
+#line 3200 "VBNET.ATG"
+ref Expression expr) {
+
+#line 3201 "VBNET.ATG"
+ List arguments; bool canBeNormal; bool canBeRedim; string name;
+ while (la.kind == 16 ||
+#line 3204 "VBNET.ATG"
+la.kind == Tokens.OpenParenthesis && Peek(1).kind == Tokens.Of) {
if (la.kind == 16) {
- Get();
- IdentifierOrKeyword(out name);
- expr = new MemberReferenceExpression(expr, name);
+ lexer.NextToken();
+ IdentifierOrKeyword(
+#line 3203 "VBNET.ATG"
+out name);
+
+#line 3203 "VBNET.ATG"
+ expr = new MemberReferenceExpression(expr, name);
} else {
- InvocationExpression(ref expr);
+ InvocationExpression(
+#line 3205 "VBNET.ATG"
+ref expr);
}
}
Expect(25);
- NormalOrReDimArgumentList(out arguments, out canBeNormal, out canBeRedim);
+ NormalOrReDimArgumentList(
+#line 3208 "VBNET.ATG"
+out arguments, out canBeNormal, out canBeRedim);
Expect(26);
+
+#line 3210 "VBNET.ATG"
expr = new InvocationExpression(expr, arguments);
if (canBeRedim == false || canBeNormal && (la.kind == Tokens.Dot || la.kind == Tokens.OpenParenthesis)) {
if (this.Errors.Count == 0) {
@@ -4494,93 +7002,135 @@ partial class Parser : AbstractParser
ReDimClauseInternal(ref expr);
}
}
-
+
}
- void CaseClause(out CaseLabel caseClause) {
+ void CaseClause(
+#line 3242 "VBNET.ATG"
+out CaseLabel caseClause) {
+
+#line 3244 "VBNET.ATG"
Expression expr = null;
Expression sexpr = null;
BinaryOperatorType op = BinaryOperatorType.None;
caseClause = null;
-
+
if (la.kind == 98) {
- Get();
- caseClause = new CaseLabel();
+ lexer.NextToken();
+
+#line 3250 "VBNET.ATG"
+ caseClause = new CaseLabel();
} else if (StartOf(42)) {
if (la.kind == 131) {
- Get();
+ lexer.NextToken();
}
switch (la.kind) {
case 28: {
- Get();
- op = BinaryOperatorType.LessThan;
+ lexer.NextToken();
+
+#line 3254 "VBNET.ATG"
+ op = BinaryOperatorType.LessThan;
break;
}
case 27: {
- Get();
- op = BinaryOperatorType.GreaterThan;
+ lexer.NextToken();
+
+#line 3255 "VBNET.ATG"
+ op = BinaryOperatorType.GreaterThan;
break;
}
case 31: {
- Get();
- op = BinaryOperatorType.LessThanOrEqual;
+ lexer.NextToken();
+
+#line 3256 "VBNET.ATG"
+ op = BinaryOperatorType.LessThanOrEqual;
break;
}
case 30: {
- Get();
- op = BinaryOperatorType.GreaterThanOrEqual;
+ lexer.NextToken();
+
+#line 3257 "VBNET.ATG"
+ op = BinaryOperatorType.GreaterThanOrEqual;
break;
}
case 10: {
- Get();
- op = BinaryOperatorType.Equality;
+ lexer.NextToken();
+
+#line 3258 "VBNET.ATG"
+ op = BinaryOperatorType.Equality;
break;
}
case 29: {
- Get();
- op = BinaryOperatorType.InEquality;
+ lexer.NextToken();
+
+#line 3259 "VBNET.ATG"
+ op = BinaryOperatorType.InEquality;
break;
}
- default: SynErr(284); break;
+ default: SynErr(287); break;
}
- Expr(out expr);
- caseClause = new CaseLabel(op, expr);
+ Expr(
+#line 3261 "VBNET.ATG"
+out expr);
+#line 3263 "VBNET.ATG"
+ caseClause = new CaseLabel(op, expr);
+
} else if (StartOf(29)) {
- Expr(out expr);
- if (la.kind == 201) {
- Get();
- Expr(out sexpr);
+ Expr(
+#line 3265 "VBNET.ATG"
+out expr);
+ if (la.kind == 202) {
+ lexer.NextToken();
+ Expr(
+#line 3265 "VBNET.ATG"
+out sexpr);
}
- caseClause = new CaseLabel(expr, sexpr);
- } else SynErr(285);
+#line 3267 "VBNET.ATG"
+ caseClause = new CaseLabel(expr, sexpr);
+
+ } else SynErr(288);
}
- void CatchClauses(out List catchClauses) {
+ void CatchClauses(
+#line 3314 "VBNET.ATG"
+out List catchClauses) {
+
+#line 3316 "VBNET.ATG"
catchClauses = new List();
TypeReference type = null;
Statement blockStmt = null;
Expression expr = null;
string name = String.Empty;
-
+
while (la.kind == 62) {
- Get();
+ lexer.NextToken();
if (StartOf(4)) {
Identifier();
- name = t.val;
+
+#line 3324 "VBNET.ATG"
+ name = t.val;
if (la.kind == 50) {
- Get();
- TypeName(out type);
+ lexer.NextToken();
+ TypeName(
+#line 3324 "VBNET.ATG"
+out type);
}
}
- if (la.kind == 214) {
- Get();
- Expr(out expr);
+ if (la.kind == 215) {
+ lexer.NextToken();
+ Expr(
+#line 3325 "VBNET.ATG"
+out expr);
}
EndOfStmt();
- Block(out blockStmt);
- catchClauses.Add(new CatchClause(type, name, blockStmt, expr));
+ Block(
+#line 3327 "VBNET.ATG"
+out blockStmt);
+
+#line 3328 "VBNET.ATG"
+ catchClauses.Add(new CatchClause(type, name, blockStmt, expr));
}
}
@@ -4589,361 +7139,359 @@ partial class Parser : AbstractParser
void ParseRoot()
{
VBNET();
- Expect(0); // expect end-of-file automatically added
}
- private bool StartOf(int s)
- {
- return set[s, lexer.LookAhead.kind];
- }
-
protected override void SynErr(int line, int col, int errorNumber)
{
- this.Errors.Error(line, col, ErrorDesc(errorNumber));
+ string s;
+ switch (errorNumber) {
+ case 0: s = "EOF expected"; break;
+ case 1: s = "EOL expected"; break;
+ case 2: s = "ident expected"; break;
+ case 3: s = "LiteralString expected"; break;
+ case 4: s = "LiteralCharacter expected"; break;
+ case 5: s = "LiteralInteger expected"; break;
+ case 6: s = "LiteralDouble expected"; break;
+ case 7: s = "LiteralSingle expected"; break;
+ case 8: s = "LiteralDecimal expected"; break;
+ case 9: s = "LiteralDate expected"; break;
+ case 10: s = "\"=\" expected"; break;
+ case 11: s = "\":\" expected"; break;
+ case 12: s = "\",\" expected"; break;
+ case 13: s = "\"&\" expected"; break;
+ case 14: s = "\"/\" expected"; break;
+ case 15: s = "\"\\\\\" expected"; break;
+ case 16: s = "\".\" expected"; break;
+ case 17: s = "\"!\" expected"; break;
+ case 18: s = "\"-\" expected"; break;
+ case 19: s = "\"+\" expected"; break;
+ case 20: s = "\"^\" expected"; break;
+ case 21: s = "\"?\" expected"; break;
+ case 22: s = "\"*\" expected"; break;
+ case 23: s = "\"{\" expected"; break;
+ case 24: s = "\"}\" expected"; break;
+ case 25: s = "\"(\" expected"; break;
+ case 26: s = "\")\" expected"; break;
+ case 27: s = "\">\" expected"; break;
+ case 28: s = "\"<\" expected"; break;
+ case 29: s = "\"<>\" expected"; break;
+ case 30: s = "\">=\" expected"; break;
+ case 31: s = "\"<=\" expected"; break;
+ case 32: s = "\"<<\" expected"; break;
+ case 33: s = "\">>\" expected"; break;
+ case 34: s = "\"+=\" expected"; break;
+ case 35: s = "\"^=\" expected"; break;
+ case 36: s = "\"-=\" expected"; break;
+ case 37: s = "\"*=\" expected"; break;
+ case 38: s = "\"/=\" expected"; break;
+ case 39: s = "\"\\\\=\" expected"; break;
+ case 40: s = "\"<<=\" expected"; break;
+ case 41: s = "\">>=\" expected"; break;
+ case 42: s = "\"&=\" expected"; break;
+ case 43: s = "\"AddHandler\" expected"; break;
+ case 44: s = "\"AddressOf\" expected"; break;
+ case 45: s = "\"Aggregate\" expected"; break;
+ case 46: s = "\"Alias\" expected"; break;
+ case 47: s = "\"And\" expected"; break;
+ case 48: s = "\"AndAlso\" expected"; break;
+ case 49: s = "\"Ansi\" expected"; break;
+ case 50: s = "\"As\" expected"; break;
+ case 51: s = "\"Ascending\" expected"; break;
+ case 52: s = "\"Assembly\" expected"; break;
+ case 53: s = "\"Auto\" expected"; break;
+ case 54: s = "\"Binary\" expected"; break;
+ case 55: s = "\"Boolean\" expected"; break;
+ case 56: s = "\"ByRef\" expected"; break;
+ case 57: s = "\"By\" expected"; break;
+ case 58: s = "\"Byte\" expected"; break;
+ case 59: s = "\"ByVal\" expected"; break;
+ case 60: s = "\"Call\" expected"; break;
+ case 61: s = "\"Case\" expected"; break;
+ case 62: s = "\"Catch\" expected"; break;
+ case 63: s = "\"CBool\" expected"; break;
+ case 64: s = "\"CByte\" expected"; break;
+ case 65: s = "\"CChar\" expected"; break;
+ case 66: s = "\"CDate\" expected"; break;
+ case 67: s = "\"CDbl\" expected"; break;
+ case 68: s = "\"CDec\" expected"; break;
+ case 69: s = "\"Char\" expected"; break;
+ case 70: s = "\"CInt\" expected"; break;
+ case 71: s = "\"Class\" expected"; break;
+ case 72: s = "\"CLng\" expected"; break;
+ case 73: s = "\"CObj\" expected"; break;
+ case 74: s = "\"Compare\" expected"; break;
+ case 75: s = "\"Const\" expected"; break;
+ case 76: s = "\"Continue\" expected"; break;
+ case 77: s = "\"CSByte\" expected"; break;
+ case 78: s = "\"CShort\" expected"; break;
+ case 79: s = "\"CSng\" expected"; break;
+ case 80: s = "\"CStr\" expected"; break;
+ case 81: s = "\"CType\" expected"; break;
+ case 82: s = "\"CUInt\" expected"; break;
+ case 83: s = "\"CULng\" expected"; break;
+ case 84: s = "\"CUShort\" expected"; break;
+ case 85: s = "\"Custom\" expected"; break;
+ case 86: s = "\"Date\" expected"; break;
+ case 87: s = "\"Decimal\" expected"; break;
+ case 88: s = "\"Declare\" expected"; break;
+ case 89: s = "\"Default\" expected"; break;
+ case 90: s = "\"Delegate\" expected"; break;
+ case 91: s = "\"Descending\" expected"; break;
+ case 92: s = "\"Dim\" expected"; break;
+ case 93: s = "\"DirectCast\" expected"; break;
+ case 94: s = "\"Distinct\" expected"; break;
+ case 95: s = "\"Do\" expected"; break;
+ case 96: s = "\"Double\" expected"; break;
+ case 97: s = "\"Each\" expected"; break;
+ case 98: s = "\"Else\" expected"; break;
+ case 99: s = "\"ElseIf\" expected"; break;
+ case 100: s = "\"End\" expected"; break;
+ case 101: s = "\"EndIf\" expected"; break;
+ case 102: s = "\"Enum\" expected"; break;
+ case 103: s = "\"Equals\" expected"; break;
+ case 104: s = "\"Erase\" expected"; break;
+ case 105: s = "\"Error\" expected"; break;
+ case 106: s = "\"Event\" expected"; break;
+ case 107: s = "\"Exit\" expected"; break;
+ case 108: s = "\"Explicit\" expected"; break;
+ case 109: s = "\"False\" expected"; break;
+ case 110: s = "\"Finally\" expected"; break;
+ case 111: s = "\"For\" expected"; break;
+ case 112: s = "\"Friend\" expected"; break;
+ case 113: s = "\"From\" expected"; break;
+ case 114: s = "\"Function\" expected"; break;
+ case 115: s = "\"Get\" expected"; break;
+ case 116: s = "\"GetType\" expected"; break;
+ case 117: s = "\"Global\" expected"; break;
+ case 118: s = "\"GoSub\" expected"; break;
+ case 119: s = "\"GoTo\" expected"; break;
+ case 120: s = "\"Group\" expected"; break;
+ case 121: s = "\"Handles\" expected"; break;
+ case 122: s = "\"If\" expected"; break;
+ case 123: s = "\"Implements\" expected"; break;
+ case 124: s = "\"Imports\" expected"; break;
+ case 125: s = "\"In\" expected"; break;
+ case 126: s = "\"Infer\" expected"; break;
+ case 127: s = "\"Inherits\" expected"; break;
+ case 128: s = "\"Integer\" expected"; break;
+ case 129: s = "\"Interface\" expected"; break;
+ case 130: s = "\"Into\" expected"; break;
+ case 131: s = "\"Is\" expected"; break;
+ case 132: s = "\"IsNot\" expected"; break;
+ case 133: s = "\"Join\" expected"; break;
+ case 134: s = "\"Key\" expected"; break;
+ case 135: s = "\"Let\" expected"; break;
+ case 136: s = "\"Lib\" expected"; break;
+ case 137: s = "\"Like\" expected"; break;
+ case 138: s = "\"Long\" expected"; break;
+ case 139: s = "\"Loop\" expected"; break;
+ case 140: s = "\"Me\" expected"; break;
+ case 141: s = "\"Mod\" expected"; break;
+ case 142: s = "\"Module\" expected"; break;
+ case 143: s = "\"MustInherit\" expected"; break;
+ case 144: s = "\"MustOverride\" expected"; break;
+ case 145: s = "\"MyBase\" expected"; break;
+ case 146: s = "\"MyClass\" expected"; break;
+ case 147: s = "\"Namespace\" expected"; break;
+ case 148: s = "\"Narrowing\" expected"; break;
+ case 149: s = "\"New\" expected"; break;
+ case 150: s = "\"Next\" expected"; break;
+ case 151: s = "\"Not\" expected"; break;
+ case 152: s = "\"Nothing\" expected"; break;
+ case 153: s = "\"NotInheritable\" expected"; break;
+ case 154: s = "\"NotOverridable\" expected"; break;
+ case 155: s = "\"Object\" expected"; break;
+ case 156: s = "\"Of\" expected"; break;
+ case 157: s = "\"Off\" expected"; break;
+ case 158: s = "\"On\" expected"; break;
+ case 159: s = "\"Operator\" expected"; break;
+ case 160: s = "\"Option\" expected"; break;
+ case 161: s = "\"Optional\" expected"; break;
+ case 162: s = "\"Or\" expected"; break;
+ case 163: s = "\"Order\" expected"; break;
+ case 164: s = "\"OrElse\" expected"; break;
+ case 165: s = "\"Overloads\" expected"; break;
+ case 166: s = "\"Overridable\" expected"; break;
+ case 167: s = "\"Overrides\" expected"; break;
+ case 168: s = "\"ParamArray\" expected"; break;
+ case 169: s = "\"Partial\" expected"; break;
+ case 170: s = "\"Preserve\" expected"; break;
+ case 171: s = "\"Private\" expected"; break;
+ case 172: s = "\"Property\" expected"; break;
+ case 173: s = "\"Protected\" expected"; break;
+ case 174: s = "\"Public\" expected"; break;
+ case 175: s = "\"RaiseEvent\" expected"; break;
+ case 176: s = "\"ReadOnly\" expected"; break;
+ case 177: s = "\"ReDim\" expected"; break;
+ case 178: s = "\"Rem\" expected"; break;
+ case 179: s = "\"RemoveHandler\" expected"; break;
+ case 180: s = "\"Resume\" expected"; break;
+ case 181: s = "\"Return\" expected"; break;
+ case 182: s = "\"SByte\" expected"; break;
+ case 183: s = "\"Select\" expected"; break;
+ case 184: s = "\"Set\" expected"; break;
+ case 185: s = "\"Shadows\" expected"; break;
+ case 186: s = "\"Shared\" expected"; break;
+ case 187: s = "\"Short\" expected"; break;
+ case 188: s = "\"Single\" expected"; break;
+ case 189: s = "\"Skip\" expected"; break;
+ case 190: s = "\"Static\" expected"; break;
+ case 191: s = "\"Step\" expected"; break;
+ case 192: s = "\"Stop\" expected"; break;
+ case 193: s = "\"Strict\" expected"; break;
+ case 194: s = "\"String\" expected"; break;
+ case 195: s = "\"Structure\" expected"; break;
+ case 196: s = "\"Sub\" expected"; break;
+ case 197: s = "\"SyncLock\" expected"; break;
+ case 198: s = "\"Take\" expected"; break;
+ case 199: s = "\"Text\" expected"; break;
+ case 200: s = "\"Then\" expected"; break;
+ case 201: s = "\"Throw\" expected"; break;
+ case 202: s = "\"To\" expected"; break;
+ case 203: s = "\"True\" expected"; break;
+ case 204: s = "\"Try\" expected"; break;
+ case 205: s = "\"TryCast\" expected"; break;
+ case 206: s = "\"TypeOf\" expected"; break;
+ case 207: s = "\"UInteger\" expected"; break;
+ case 208: s = "\"ULong\" expected"; break;
+ case 209: s = "\"Unicode\" expected"; break;
+ case 210: s = "\"Until\" expected"; break;
+ case 211: s = "\"UShort\" expected"; break;
+ case 212: s = "\"Using\" expected"; break;
+ case 213: s = "\"Variant\" expected"; break;
+ case 214: s = "\"Wend\" expected"; break;
+ case 215: s = "\"When\" expected"; break;
+ case 216: s = "\"Where\" expected"; break;
+ case 217: s = "\"While\" expected"; break;
+ case 218: s = "\"Widening\" expected"; break;
+ case 219: s = "\"With\" expected"; break;
+ case 220: s = "\"WithEvents\" expected"; break;
+ case 221: s = "\"WriteOnly\" expected"; break;
+ case 222: s = "\"Xor\" expected"; break;
+ case 223: s = "??? expected"; break;
+ case 224: s = "invalid EndOfStmt"; break;
+ case 225: s = "invalid OptionStmt"; break;
+ case 226: s = "invalid OptionStmt"; break;
+ case 227: s = "invalid GlobalAttributeSection"; break;
+ case 228: s = "invalid GlobalAttributeSection"; break;
+ case 229: s = "invalid NamespaceMemberDecl"; break;
+ case 230: s = "invalid OptionValue"; break;
+ case 231: s = "invalid ImportClause"; break;
+ case 232: s = "invalid Identifier"; break;
+ case 233: s = "invalid TypeModifier"; break;
+ case 234: s = "invalid NonModuleDeclaration"; break;
+ case 235: s = "invalid NonModuleDeclaration"; break;
+ case 236: s = "invalid TypeParameterConstraints"; break;
+ case 237: s = "invalid TypeParameterConstraint"; break;
+ case 238: s = "invalid NonArrayTypeName"; break;
+ case 239: s = "invalid MemberModifier"; break;
+ case 240: s = "invalid StructureMemberDecl"; break;
+ case 241: s = "invalid StructureMemberDecl"; break;
+ case 242: s = "invalid StructureMemberDecl"; break;
+ case 243: s = "invalid StructureMemberDecl"; break;
+ case 244: s = "invalid StructureMemberDecl"; break;
+ case 245: s = "invalid StructureMemberDecl"; break;
+ case 246: s = "invalid StructureMemberDecl"; break;
+ case 247: s = "invalid StructureMemberDecl"; break;
+ case 248: s = "invalid InterfaceMemberDecl"; break;
+ case 249: s = "invalid InterfaceMemberDecl"; break;
+ case 250: s = "invalid Expr"; break;
+ case 251: s = "invalid Charset"; break;
+ case 252: s = "invalid IdentifierForFieldDeclaration"; break;
+ case 253: s = "invalid VariableDeclaratorPartAfterIdentifier"; break;
+ case 254: s = "invalid AccessorDecls"; break;
+ case 255: s = "invalid EventAccessorDeclaration"; break;
+ case 256: s = "invalid OverloadableOperator"; break;
+ case 257: s = "invalid EventMemberSpecifier"; break;
+ case 258: s = "invalid AssignmentOperator"; break;
+ case 259: s = "invalid SimpleNonInvocationExpression"; break;
+ case 260: s = "invalid SimpleNonInvocationExpression"; break;
+ case 261: s = "invalid SimpleNonInvocationExpression"; break;
+ case 262: s = "invalid SimpleNonInvocationExpression"; break;
+ case 263: s = "invalid PrimitiveTypeName"; break;
+ case 264: s = "invalid CastTarget"; break;
+ case 265: s = "invalid ComparisonExpr"; break;
+ case 266: s = "invalid FromOrAggregateQueryOperator"; break;
+ case 267: s = "invalid QueryOperator"; break;
+ case 268: s = "invalid PartitionQueryOperator"; break;
+ case 269: s = "invalid Argument"; break;
+ case 270: s = "invalid QualIdentAndTypeArguments"; break;
+ case 271: s = "invalid AttributeArguments"; break;
+ case 272: s = "invalid ParameterModifier"; break;
+ case 273: s = "invalid Statement"; break;
+ case 274: s = "invalid LabelName"; break;
+ case 275: s = "invalid EmbeddedStatement"; break;
+ case 276: s = "invalid EmbeddedStatement"; break;
+ case 277: s = "invalid EmbeddedStatement"; break;
+ case 278: s = "invalid EmbeddedStatement"; break;
+ case 279: s = "invalid EmbeddedStatement"; break;
+ case 280: s = "invalid EmbeddedStatement"; break;
+ case 281: s = "invalid EmbeddedStatement"; break;
+ case 282: s = "invalid WhileOrUntil"; break;
+ case 283: s = "invalid SingleLineStatementList"; break;
+ case 284: s = "invalid SingleLineStatementList"; break;
+ case 285: s = "invalid OnErrorStatement"; break;
+ case 286: s = "invalid ResumeStatement"; break;
+ case 287: s = "invalid CaseClause"; break;
+ case 288: s = "invalid CaseClause"; break;
+
+ default: s = "error " + errorNumber; break;
+ }
+ this.Errors.Error(line, col, s);
}
-
- static bool[,] set = {
- {T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, T,T,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,T,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,x,T, x,x,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,x,x,T, x,x,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,T,x,x, T,x,x,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,T,x, x,T,T,x, x,x,x,x, x,x,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,x,x,T, x,x,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,T,x,x, T,x,x,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,x,x, x,x,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, T,T,T,T, T,x,T,x, x,x,x,x, x,x,T,T, x,x,T,x, T,x,x,x, T,T,T,x, x,x,x,x, T,x,x,x, x,x,T,x, x,T,T,x, x,T,x,x, x,x,x,x, x,T,T,T, x,x,x,T, x,x,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,T,T,x, T,T,T,T, T,T,x,T, x,x,x,x, x,x,x,x, T,T,x,x, T,x,x,x, x,x,T,T, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,T,x,T, T,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,T,x, T,x,T,x, T,T,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,T,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,T,x, T,x,x,x, x,x,x,x, x,x,T,x, x,x,T,x, x,x,x,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,T,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,T,x, T,x,T,T, T,T,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,x, T,T,T,x, T,x,T,T, T,T,x,T, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,T,T, x,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,T,T, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,T,x, T,T,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,T,T,T, T,T,T,T, T,T,x,T, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,x,x, T,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,T,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,T,x, T,x,T,T, T,T,T,x, x,x,T,T, T,T,x,T, x,T,x,x, T,T,T,x, T,x,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,x,T,x, x,x,x,x},
- {x,T,T,T, T,T,T,T, T,T,T,T, T,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,T,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,T,x, T,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,T,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,T,x, T,x,T,T, T,T,T,x, x,x,T,T, T,T,x,T, x,T,x,x, T,T,T,x, T,x,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,x,T,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,T,T, x,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,T,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,T,T, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,T,x, T,T,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,T,x, T,T,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,T,T, x,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,T,x, T,T,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,x,x, x,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,T,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,T,x, T,x,T,T, T,T,T,x, x,x,T,T, T,T,x,T, x,T,x,x, T,T,T,x, T,x,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,x,T,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, T,x,x,x, T,x,T,T, x,x,T,T, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,T,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,T,T, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,T,x, T,T,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,T, T,x,x,x, x,T,x,x, x,T,T,x, x,x,T,x, T,T,T,T, T,T,T,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,x,x, T,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,T,x,T, x,x,x,x, T,T,x,x, T,x,x,T, x,x,T,x, T,T,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,T,x, T,x,T,T, T,T,T,x, x,x,T,T, T,T,x,T, x,T,x,x, T,T,T,x, T,x,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,x,T,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, T,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,T,x,x, x,x,x,T, x,x,x,x, x,x,x,x},
- {x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x}
-
- };
- string ErrorDesc(int errorNumber)
+ private bool StartOf(int s)
{
- switch (errorNumber) {
- case 0: return "EOF expected";
- case 1: return "EOL expected";
- case 2: return "ident expected";
- case 3: return "LiteralString expected";
- case 4: return "LiteralCharacter expected";
- case 5: return "LiteralInteger expected";
- case 6: return "LiteralDouble expected";
- case 7: return "LiteralSingle expected";
- case 8: return "LiteralDecimal expected";
- case 9: return "LiteralDate expected";
- case 10: return "\"=\" expected";
- case 11: return "\":\" expected";
- case 12: return "\",\" expected";
- case 13: return "\"&\" expected";
- case 14: return "\"/\" expected";
- case 15: return "\"\\\\\" expected";
- case 16: return "\".\" expected";
- case 17: return "\"!\" expected";
- case 18: return "\"-\" expected";
- case 19: return "\"+\" expected";
- case 20: return "\"^\" expected";
- case 21: return "\"?\" expected";
- case 22: return "\"*\" expected";
- case 23: return "\"{\" expected";
- case 24: return "\"}\" expected";
- case 25: return "\"(\" expected";
- case 26: return "\")\" expected";
- case 27: return "\">\" expected";
- case 28: return "\"<\" expected";
- case 29: return "\"<>\" expected";
- case 30: return "\">=\" expected";
- case 31: return "\"<=\" expected";
- case 32: return "\"<<\" expected";
- case 33: return "\">>\" expected";
- case 34: return "\"+=\" expected";
- case 35: return "\"^=\" expected";
- case 36: return "\"-=\" expected";
- case 37: return "\"*=\" expected";
- case 38: return "\"/=\" expected";
- case 39: return "\"\\\\=\" expected";
- case 40: return "\"<<=\" expected";
- case 41: return "\">>=\" expected";
- case 42: return "\"&=\" expected";
- case 43: return "\"AddHandler\" expected";
- case 44: return "\"AddressOf\" expected";
- case 45: return "\"Aggregate\" expected";
- case 46: return "\"Alias\" expected";
- case 47: return "\"And\" expected";
- case 48: return "\"AndAlso\" expected";
- case 49: return "\"Ansi\" expected";
- case 50: return "\"As\" expected";
- case 51: return "\"Ascending\" expected";
- case 52: return "\"Assembly\" expected";
- case 53: return "\"Auto\" expected";
- case 54: return "\"Binary\" expected";
- case 55: return "\"Boolean\" expected";
- case 56: return "\"ByRef\" expected";
- case 57: return "\"By\" expected";
- case 58: return "\"Byte\" expected";
- case 59: return "\"ByVal\" expected";
- case 60: return "\"Call\" expected";
- case 61: return "\"Case\" expected";
- case 62: return "\"Catch\" expected";
- case 63: return "\"CBool\" expected";
- case 64: return "\"CByte\" expected";
- case 65: return "\"CChar\" expected";
- case 66: return "\"CDate\" expected";
- case 67: return "\"CDbl\" expected";
- case 68: return "\"CDec\" expected";
- case 69: return "\"Char\" expected";
- case 70: return "\"CInt\" expected";
- case 71: return "\"Class\" expected";
- case 72: return "\"CLng\" expected";
- case 73: return "\"CObj\" expected";
- case 74: return "\"Compare\" expected";
- case 75: return "\"Const\" expected";
- case 76: return "\"Continue\" expected";
- case 77: return "\"CSByte\" expected";
- case 78: return "\"CShort\" expected";
- case 79: return "\"CSng\" expected";
- case 80: return "\"CStr\" expected";
- case 81: return "\"CType\" expected";
- case 82: return "\"CUInt\" expected";
- case 83: return "\"CULng\" expected";
- case 84: return "\"CUShort\" expected";
- case 85: return "\"Custom\" expected";
- case 86: return "\"Date\" expected";
- case 87: return "\"Decimal\" expected";
- case 88: return "\"Declare\" expected";
- case 89: return "\"Default\" expected";
- case 90: return "\"Delegate\" expected";
- case 91: return "\"Descending\" expected";
- case 92: return "\"Dim\" expected";
- case 93: return "\"DirectCast\" expected";
- case 94: return "\"Distinct\" expected";
- case 95: return "\"Do\" expected";
- case 96: return "\"Double\" expected";
- case 97: return "\"Each\" expected";
- case 98: return "\"Else\" expected";
- case 99: return "\"ElseIf\" expected";
- case 100: return "\"End\" expected";
- case 101: return "\"EndIf\" expected";
- case 102: return "\"Enum\" expected";
- case 103: return "\"Equals\" expected";
- case 104: return "\"Erase\" expected";
- case 105: return "\"Error\" expected";
- case 106: return "\"Event\" expected";
- case 107: return "\"Exit\" expected";
- case 108: return "\"Explicit\" expected";
- case 109: return "\"False\" expected";
- case 110: return "\"Finally\" expected";
- case 111: return "\"For\" expected";
- case 112: return "\"Friend\" expected";
- case 113: return "\"From\" expected";
- case 114: return "\"Function\" expected";
- case 115: return "\"Get\" expected";
- case 116: return "\"GetType\" expected";
- case 117: return "\"Global\" expected";
- case 118: return "\"GoSub\" expected";
- case 119: return "\"GoTo\" expected";
- case 120: return "\"Group\" expected";
- case 121: return "\"Handles\" expected";
- case 122: return "\"If\" expected";
- case 123: return "\"Implements\" expected";
- case 124: return "\"Imports\" expected";
- case 125: return "\"In\" expected";
- case 126: return "\"Infer\" expected";
- case 127: return "\"Inherits\" expected";
- case 128: return "\"Integer\" expected";
- case 129: return "\"Interface\" expected";
- case 130: return "\"Into\" expected";
- case 131: return "\"Is\" expected";
- case 132: return "\"IsNot\" expected";
- case 133: return "\"Join\" expected";
- case 134: return "\"Let\" expected";
- case 135: return "\"Lib\" expected";
- case 136: return "\"Like\" expected";
- case 137: return "\"Long\" expected";
- case 138: return "\"Loop\" expected";
- case 139: return "\"Me\" expected";
- case 140: return "\"Mod\" expected";
- case 141: return "\"Module\" expected";
- case 142: return "\"MustInherit\" expected";
- case 143: return "\"MustOverride\" expected";
- case 144: return "\"MyBase\" expected";
- case 145: return "\"MyClass\" expected";
- case 146: return "\"Namespace\" expected";
- case 147: return "\"Narrowing\" expected";
- case 148: return "\"New\" expected";
- case 149: return "\"Next\" expected";
- case 150: return "\"Not\" expected";
- case 151: return "\"Nothing\" expected";
- case 152: return "\"NotInheritable\" expected";
- case 153: return "\"NotOverridable\" expected";
- case 154: return "\"Object\" expected";
- case 155: return "\"Of\" expected";
- case 156: return "\"Off\" expected";
- case 157: return "\"On\" expected";
- case 158: return "\"Operator\" expected";
- case 159: return "\"Option\" expected";
- case 160: return "\"Optional\" expected";
- case 161: return "\"Or\" expected";
- case 162: return "\"Order\" expected";
- case 163: return "\"OrElse\" expected";
- case 164: return "\"Overloads\" expected";
- case 165: return "\"Overridable\" expected";
- case 166: return "\"Overrides\" expected";
- case 167: return "\"ParamArray\" expected";
- case 168: return "\"Partial\" expected";
- case 169: return "\"Preserve\" expected";
- case 170: return "\"Private\" expected";
- case 171: return "\"Property\" expected";
- case 172: return "\"Protected\" expected";
- case 173: return "\"Public\" expected";
- case 174: return "\"RaiseEvent\" expected";
- case 175: return "\"ReadOnly\" expected";
- case 176: return "\"ReDim\" expected";
- case 177: return "\"Rem\" expected";
- case 178: return "\"RemoveHandler\" expected";
- case 179: return "\"Resume\" expected";
- case 180: return "\"Return\" expected";
- case 181: return "\"SByte\" expected";
- case 182: return "\"Select\" expected";
- case 183: return "\"Set\" expected";
- case 184: return "\"Shadows\" expected";
- case 185: return "\"Shared\" expected";
- case 186: return "\"Short\" expected";
- case 187: return "\"Single\" expected";
- case 188: return "\"Skip\" expected";
- case 189: return "\"Static\" expected";
- case 190: return "\"Step\" expected";
- case 191: return "\"Stop\" expected";
- case 192: return "\"Strict\" expected";
- case 193: return "\"String\" expected";
- case 194: return "\"Structure\" expected";
- case 195: return "\"Sub\" expected";
- case 196: return "\"SyncLock\" expected";
- case 197: return "\"Take\" expected";
- case 198: return "\"Text\" expected";
- case 199: return "\"Then\" expected";
- case 200: return "\"Throw\" expected";
- case 201: return "\"To\" expected";
- case 202: return "\"True\" expected";
- case 203: return "\"Try\" expected";
- case 204: return "\"TryCast\" expected";
- case 205: return "\"TypeOf\" expected";
- case 206: return "\"UInteger\" expected";
- case 207: return "\"ULong\" expected";
- case 208: return "\"Unicode\" expected";
- case 209: return "\"Until\" expected";
- case 210: return "\"UShort\" expected";
- case 211: return "\"Using\" expected";
- case 212: return "\"Variant\" expected";
- case 213: return "\"Wend\" expected";
- case 214: return "\"When\" expected";
- case 215: return "\"Where\" expected";
- case 216: return "\"While\" expected";
- case 217: return "\"Widening\" expected";
- case 218: return "\"With\" expected";
- case 219: return "\"WithEvents\" expected";
- case 220: return "\"WriteOnly\" expected";
- case 221: return "\"Xor\" expected";
- case 222: return "??? expected";
- case 223: return "invalid EndOfStmt";
- case 224: return "invalid OptionStmt";
- case 225: return "invalid OptionStmt";
- case 226: return "invalid GlobalAttributeSection";
- case 227: return "invalid GlobalAttributeSection";
- case 228: return "invalid NamespaceMemberDecl";
- case 229: return "invalid OptionValue";
- case 230: return "invalid ImportClause";
- case 231: return "invalid Identifier";
- case 232: return "invalid AttributeSection";
- case 233: return "invalid TypeModifier";
- case 234: return "invalid NonModuleDeclaration";
- case 235: return "invalid NonModuleDeclaration";
- case 236: return "invalid TypeParameterConstraints";
- case 237: return "invalid TypeParameterConstraint";
- case 238: return "invalid NonArrayTypeName";
- case 239: return "invalid MemberModifier";
- case 240: return "invalid StructureMemberDecl";
- case 241: return "invalid StructureMemberDecl";
- case 242: return "invalid StructureMemberDecl";
- case 243: return "invalid StructureMemberDecl";
- case 244: return "invalid StructureMemberDecl";
- case 245: return "invalid StructureMemberDecl";
- case 246: return "invalid StructureMemberDecl";
- case 247: return "invalid StructureMemberDecl";
- case 248: return "invalid InterfaceMemberDecl";
- case 249: return "invalid InterfaceMemberDecl";
- case 250: return "invalid Expr";
- case 251: return "invalid Charset";
- case 252: return "invalid IdentifierForFieldDeclaration";
- case 253: return "invalid VariableDeclaratorPartAfterIdentifier";
- case 254: return "invalid AccessorDecls";
- case 255: return "invalid EventAccessorDeclaration";
- case 256: return "invalid OverloadableOperator";
- case 257: return "invalid EventMemberSpecifier";
- case 258: return "invalid AssignmentOperator";
- case 259: return "invalid SimpleNonInvocationExpression";
- case 260: return "invalid PrimitiveTypeName";
- case 261: return "invalid CastTarget";
- case 262: return "invalid ComparisonExpr";
- case 263: return "invalid FromOrAggregateQueryOperator";
- case 264: return "invalid QueryOperator";
- case 265: return "invalid PartitionQueryOperator";
- case 266: return "invalid Argument";
- case 267: return "invalid QualIdentAndTypeArguments";
- case 268: return "invalid AttributeArguments";
- case 269: return "invalid ParameterModifier";
- case 270: return "invalid Statement";
- case 271: return "invalid LabelName";
- case 272: return "invalid EmbeddedStatement";
- case 273: return "invalid EmbeddedStatement";
- case 274: return "invalid EmbeddedStatement";
- case 275: return "invalid EmbeddedStatement";
- case 276: return "invalid EmbeddedStatement";
- case 277: return "invalid EmbeddedStatement";
- case 278: return "invalid EmbeddedStatement";
- case 279: return "invalid WhileOrUntil";
- case 280: return "invalid SingleLineStatementList";
- case 281: return "invalid SingleLineStatementList";
- case 282: return "invalid OnErrorStatement";
- case 283: return "invalid ResumeStatement";
- case 284: return "invalid CaseClause";
- case 285: return "invalid CaseClause";
-
- default: return "error " + errorNumber;
- }
+ return set[s, lexer.LookAhead.kind];
}
+
+ static bool[,] set = {
+ {T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, T,T,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, x,x,x,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,x,T, x,x,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,x,x,T, x,x,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,T,x,x, T,x,x,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,T, x,x,T,T, x,x,x,x, x,x,x,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,x,x,T, x,x,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,T,x,x, T,x,x,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,x, x,x,x,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, T,T,T,T, T,x,T,x, x,x,x,x, x,x,T,T, x,x,T,x, T,x,x,x, T,T,T,x, x,x,x,x, T,x,x,x, x,x,T,x, x,T,T,x, x,T,x,x, x,x,x,x, x,x,T,T, T,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, x,x,x,T, x,T,T,T, x,T,T,T, T,T,T,x, T,x,x,x, x,x,x,x, x,T,T,x, x,T,x,x, x,x,x,T, T,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,T,x, T,T,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,T,x,T, x,T,T,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,T,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,T,x, T,x,x,x, x,x,x,x, x,x,T,x, x,x,T,x, x,x,x,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,T,x,T, T,T,T,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,T,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, T,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, x,T,T,T, x,T,x,T, T,T,T,x, T,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,T,T, x,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,T, x,T,T,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,T,T,T, T,T,T,T, T,T,x,T, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,x,x, x,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, T,T,T,T, x,x,x,T, T,T,T,x, T,x,T,x, x,T,T,T, x,T,x,T, T,T,T,T, T,T,T,T, T,x,x,x, T,T,x,T, x,x,x,x, x},
+ {x,T,T,T, T,T,T,T, T,T,T,T, T,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,T,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,T,x, T,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, T,T,T,T, x,x,x,T, T,T,T,x, T,x,T,x, x,T,T,T, x,T,x,T, T,T,T,T, T,T,T,T, T,x,x,x, T,T,x,T, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,T,T, x,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,T,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,T, x,T,T,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,T,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,T, x,T,T,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,x,x,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,T,T, x,x,T,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,T, x,T,T,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,x,x, x,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, T,T,T,T, x,x,x,T, T,T,T,x, T,x,T,x, x,T,T,T, x,T,x,T, T,T,T,T, T,T,T,T, T,x,x,x, T,T,x,T, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, T,x,x,x, T,x,T,T, x,x,T,T, x,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,T,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,T, x,T,T,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, x,x,x,T, T,T,T,T, T,T,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, x,T,T,x, T,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,T,x,x, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,T, T,T,x,x, x,x,T,x, x,x,T,T, x,x,x,T, x,T,T,T, T,T,T,T, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,T, T,T,T,T, T,T,x,x, x,x,x,x, T,x,x,x, x,x,x,T, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,x,x, x,T,x,T, T,T,T,T, x,T,T,x, T,x,x,T, T,T,T,T, T,T,T,x, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,T, x,x,x,T, T,T,T,T, T,x,x,x, T,x,x,T, T,T,x,T, T,T,x,T, x,T,x,x, T,T,x,T, T,x,T,x, x,x,T,x, T,x,T,x, x,T,x,x, x,x,T,x, T,x,x,x, x,T,T,x, x,T,x,x, T,x,x,T, x,T,T,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,T, x,T,x,T, T,T,T,T, x,x,x,T, T,T,T,x, T,x,T,x, x,T,T,T, x,T,x,T, T,T,T,T, T,T,T,T, T,x,x,x, T,T,x,T, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, T,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,x,x,x, x,T,x,x, x,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,T, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,T,T, x,x,x,x, x,x,x,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,x, x},
+ {x,x,x,x, x,x,x,x, x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, T,T,T,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,T, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x}
+ };
} // end Parser
-} // end namespace
+}
\ No newline at end of file
diff --git a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/VBNET.ATG b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/VBNET.ATG
index 233f732046..36466578a5 100644
--- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/VBNET.ATG
+++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/VBNET.ATG
@@ -8,8 +8,6 @@ using ASTAttribute = ICSharpCode.NRefactory.Ast.Attribute;
COMPILER VBNET
-$frameDir=../Frames
-
/* START AUTOGENERATED TOKENS SECTION */
TOKENS
/* ----- terminal classes ----- */
@@ -23,6 +21,12 @@ TOKENS
LiteralSingle
LiteralDecimal
LiteralDate
+ XmlOpenTag
+ XmlCloseTag
+ XmlStartInlineVB
+ XmlEndInlineVB
+ XmlCloseTagEmptyElement
+ XmlOpenEndTag
/* ----- special character ----- */
"="
@@ -151,6 +155,7 @@ TOKENS
"Is"
"IsNot"
"Join"
+ "Key"
"Let"
"Lib"
"Like"
@@ -337,7 +342,7 @@ ImportClause
}
.)
) | ( (. string prefix = null; .)
- "<" Identifier (. prefix = t.val; .) "=" LiteralString /* TODO support single-quote xml strings */ (. u = new Using(t.literalValue as string, prefix); .) ">"
+ "<" Identifier (. prefix = t.val; .) [ ":" Identifier (. prefix += ":" + t.val; .) ] "=" LiteralString /* TODO support single-quote xml strings */ (. u = new Using(t.literalValue as string, prefix); .) ">"
)
.
@@ -372,7 +377,7 @@ NamespaceMemberDecl
.
/* 4.9.1 */
-TypeParameterList<. List templates .>
+TypeParameterList templates>
(.
TemplateDefinition template;
.)
@@ -428,7 +433,7 @@ TypeParameterConstraint
.
/* 6.4.2 */
-NonModuleDeclaration<. ModifierList m, List attributes .>
+NonModuleDeclaration attributes>
(.
TypeReference typeRef = null;
List baseInterfaces = null;
@@ -765,7 +770,7 @@ EnumMemberDecl
EndOfStmt
.
-ClassMemberDecl<. ModifierList m, List attributes .> =
+ClassMemberDecl attributes> =
StructureMemberDecl
.
@@ -779,7 +784,7 @@ ClassBaseType
.
/* 7.6.1 */
-StructureMemberDecl<. ModifierList m, List attributes .>
+StructureMemberDecl attributes>
(.
TypeReference type = null;
List p = new List();
@@ -1373,7 +1378,7 @@ AccessorDecls
.
/* 9.7.1 */
-GetAccessorDecl<. out PropertyGetRegion getBlock, List attributes .>
+GetAccessorDecl attributes>
(. Statement stmt = null; Modifiers m; .)
=
PropertyAccessorAccessModifier
@@ -1389,7 +1394,7 @@ GetAccessorDecl<. out PropertyGetRegion getBlock, List attribu
.
/* 9.7.2 */
-SetAccessorDecl<. out PropertySetRegion setBlock, List attributes .>
+SetAccessorDecl attributes>
(.
Statement stmt = null;
List p = new List();
@@ -1413,7 +1418,7 @@ SetAccessorDecl<. out PropertySetRegion setBlock, List attribu
.
/* 9.5 */
-ConstantDeclarator<. List constantDeclaration .>
+ConstantDeclarator constantDeclaration>
(.
Expression expr = null;
TypeReference type = null;
@@ -1432,13 +1437,13 @@ ConstantDeclarator<. List constantDeclaration .>
.
/* 9.6 */
-VariableDeclarator<. List fieldDeclaration .>
+VariableDeclarator fieldDeclaration>
=
Identifier (. string name = t.val; .)
VariableDeclaratorPartAfterIdentifier
.
-VariableDeclaratorPartAfterIdentifier<. List fieldDeclaration, string name .>
+VariableDeclaratorPartAfterIdentifier fieldDeclaration, string name>
(.
Expression expr = null;
TypeReference type = null;
@@ -1506,7 +1511,7 @@ VariableDeclaratorPartAfterIdentifier<. List fieldDeclarati
.
/* 6.8 */
-ArrayInitializationModifier<. out List arrayModifiers .>
+ArrayInitializationModifier arrayModifiers>
(.
arrayModifiers = null;
.) =
@@ -1514,7 +1519,7 @@ ArrayInitializationModifier<. out List arrayModifiers .>
.
/* 7.5.4.3 */
-InitializationRankList<. out List rank .>
+InitializationRankList rank>
(.
rank = new List();
Expression expr = null;
@@ -1561,7 +1566,7 @@ Charset
.
/* 9.2.6 */
-HandlesClause<. out List handlesClause .>
+HandlesClause handlesClause>
(.
handlesClause = new List();
string name;
@@ -1571,7 +1576,7 @@ HandlesClause<. out List handlesClause .>
.
/* 7.8. */
-InterfaceBase<. out List bases .>
+InterfaceBase bases>
(.
TypeReference type;
bases = new List();
@@ -1586,7 +1591,7 @@ InterfaceBase<. out List bases .>
.
/* 7.2 */
-TypeImplementsClause<. out List baseInterfaces .>
+TypeImplementsClause baseInterfaces>
(.
baseInterfaces = new List();
TypeReference type = null;
@@ -1603,7 +1608,7 @@ TypeImplementsClause<. out List baseInterfaces .>
.
/* 9.1 */
-ImplementsClause<. out List baseInterfaces .>
+ImplementsClause baseInterfaces>
(.
baseInterfaces = new List();
TypeReference type = null;
@@ -2062,7 +2067,7 @@ QueryExpr
.)
.
-FromOrAggregateQueryOperator<. List middleClauses .>
+FromOrAggregateQueryOperator middleClauses>
(.
QueryExpressionFromClause fromClause = null;
QueryExpressionAggregateClause aggregateClause = null;
@@ -2073,7 +2078,7 @@ FromOrAggregateQueryOperator<. List middleClauses .>
(. middleClauses.Add(aggregateClause); .)
.
-QueryOperator<. List middleClauses .>
+QueryOperator middleClauses>
(.
QueryExpressionJoinVBClause joinClause = null;
QueryExpressionGroupVBClause groupByClause = null;
@@ -2101,7 +2106,7 @@ QueryOperator<. List middleClauses .>
(. middleClauses.Add(groupByClause); .)
.
-OrderByQueryOperator<. List middleClauses .>
+OrderByQueryOperator middleClauses>
(.
QueryExpressionOrderClause orderClause = new QueryExpressionOrderClause();
orderClause.StartLocation = la.Location;
@@ -2115,7 +2120,7 @@ OrderByQueryOperator<. List middleClauses .>
.)
.
-OrderExpressionList<. out List orderings .>
+OrderExpressionList orderings>
(.
orderings = new List();
QueryExpressionOrdering ordering = null;
@@ -2184,7 +2189,7 @@ FromQueryOperator
.)
.
-SelectQueryOperator<. List middleClauses .>
+SelectQueryOperator middleClauses>
(.
QueryExpressionSelectVBClause selectClause = new QueryExpressionSelectVBClause();
selectClause.StartLocation = la.Location;
@@ -2196,7 +2201,7 @@ SelectQueryOperator<. List middleClauses .>
.)
.
-DistinctQueryOperator<. List middleClauses .>
+DistinctQueryOperator middleClauses>
(.
QueryExpressionDistinctClause distinctClause = new QueryExpressionDistinctClause();
distinctClause.StartLocation = la.Location;
@@ -2208,7 +2213,7 @@ DistinctQueryOperator<. List middleClauses .>
.)
.
-WhereQueryOperator<. List middleClauses .>
+WhereQueryOperator middleClauses>
(.
QueryExpressionWhereClause whereClause = new QueryExpressionWhereClause();
whereClause.StartLocation = la.Location;
@@ -2262,7 +2267,7 @@ AggregateQueryOperator
.)
.
-LetQueryOperator<. List middleClauses .>
+LetQueryOperator middleClauses>
(.
QueryExpressionLetVBClause letClause = new QueryExpressionLetVBClause();
letClause.StartLocation = la.Location;
@@ -2274,7 +2279,7 @@ LetQueryOperator<. List middleClauses .>
.)
.
-ExpressionRangeVariableDeclarationList<. List variables .>
+ExpressionRangeVariableDeclarationList variables>
(.
ExpressionRangeVariable variable = null;
.) =
@@ -2333,7 +2338,7 @@ JoinQueryOperator
.)
.
-CollectionRangeVariableDeclarationList<. List rangeVariables .>
+CollectionRangeVariableDeclarationList rangeVariables>
(. CollectionRangeVariable variableDeclaration; .)
=
CollectionRangeVariableDeclaration
@@ -2392,7 +2397,7 @@ MemberInitializer
.
/* 9.3.2 */
-ArgumentList<. out List arguments .>
+ArgumentList arguments>
(.
arguments = new List