Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

update generated files

  • Loading branch information...
commit aac36f81e4edfe4f26ddc3394c8c295a88c94075 1 parent 2f24817
Rodrigo B. de Oliveira bamboo authored
8 src/UnityScript.Tests/ParserTestFixture.Generated.boo
View
@@ -66,6 +66,14 @@ partial class ParserTestFixture:
RunTestCase("tests/parser/for-1.js")
+ [Test] def for_each_in_1():
+ RunTestCase("tests/parser/for-each-in-1.js")
+
+
+ [Test] def for_each_in_2():
+ RunTestCase("tests/parser/for-each-in-2.js")
+
+
[Test] def for_loop_with_array_1():
RunTestCase("tests/parser/for-loop-with-array-1.js")
532 src/UnityScript/Parser/UnityScriptLexer.boo
View
@@ -40,116 +40,118 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
public static final CONTINUE = 9
public static final DO = 10
public static final ELSE = 11
- public static final ENUM = 12
- public static final EXTENDS = 13
- public static final FALSE = 14
- public static final FINAL = 15
- public static final FINALLY = 16
- public static final FOR = 17
- public static final FUNCTION = 18
- public static final GET = 19
- public static final IF = 20
- public static final IMPORT = 21
- public static final IMPLEMENTS = 22
- public static final IN = 23
- public static final INTERFACE = 24
- public static final INSTANCEOF = 25
- public static final NEW = 26
- public static final NULL = 27
- public static final RETURN = 28
- public static final PUBLIC = 29
- public static final PROTECTED = 30
- public static final INTERNAL = 31
- public static final OVERRIDE = 32
- public static final PARTIAL = 33
- public static final PRIVATE = 34
- public static final SET = 35
- public static final STATIC = 36
- public static final SUPER = 37
- public static final THIS = 38
- public static final THROW = 39
- public static final TRUE = 40
- public static final TRY = 41
- public static final TYPEOF = 42
- public static final VAR = 43
- public static final VIRTUAL = 44
- public static final WHILE = 45
- public static final YIELD = 46
- public static final SWITCH = 47
- public static final CASE = 48
- public static final DEFAULT = 49
- public static final INPLACE_DIVISION = 50
- public static final INPLACE_ADD = 51
- public static final INPLACE_SUBTRACT = 52
- public static final INPLACE_MULTIPLY = 53
- public static final SL_COMMENT = 54
- public static final PRAGMA_ON = 55
- public static final PRAGMA_OFF = 56
- public static final ID = 57
- public static final DOUBLE_QUOTED_STRING = 58
- public static final LBRACE = 59
- public static final RBRACE = 60
- public static final LPAREN = 61
- public static final RPAREN = 62
- public static final DOT = 63
- public static final COLON = 64
- public static final COMMA = 65
- public static final LBRACK = 66
- public static final RBRACK = 67
- public static final BITWISE_OR = 68
- public static final INPLACE_BITWISE_OR = 69
- public static final BITWISE_AND = 70
- public static final BITWISE_XOR = 71
- public static final INPLACE_BITWISE_AND = 72
- public static final LOGICAL_OR = 73
- public static final LOGICAL_AND = 74
- public static final EOS = 75
- public static final ASSIGN = 76
- public static final INCREMENT = 77
- public static final DECREMENT = 78
- public static final ADD = 79
- public static final SUBTRACT = 80
- public static final MODULUS = 81
- public static final MULTIPLY = 82
- public static final EQUALITY = 83
- public static final INEQUALITY = 84
- public static final QUESTION_MARK = 85
- public static final BITWISE_NOT = 86
- public static final REFERENCE_EQUALITY = 87
- public static final REFERENCE_INEQUALITY = 88
- public static final LESS_THAN = 89
- public static final LESS_THAN_OR_EQUAL = 90
- public static final SHIFT_LEFT = 91
- public static final INPLACE_SHIFT_LEFT = 92
- public static final GREATER_THAN = 93
- public static final GREATER_THAN_OR_EQUAL = 94
- public static final SHIFT_RIGHT = 95
- public static final INPLACE_SHIFT_RIGHT = 96
- public static final AT = 97
- public static final SCRIPT_ATTRIBUTE_MARKER = 98
- public static final ASSEMBLY_ATTRIBUTE_MARKER = 99
- public static final INPLACE_BITWISE_XOR = 100
- public static final NOT = 101
- public static final DIVISION = 102
- public static final RE_LITERAL = 103
- public static final DOUBLE = 104
- public static final INT = 105
- public static final LONG = 106
- public static final SINGLE_QUOTED_STRING = 107
- public static final DOUBLE_SUFFIX = 108
- public static final EXPONENT = 109
- public static final PRAGMA_WHITE_SPACE = 110
- public static final WHITE_SPACE = 111
- public static final DQS_ESC = 112
- public static final SQS_ESC = 113
- public static final SESC = 114
- public static final ML_COMMENT = 115
- public static final RE_CHAR = 116
- public static final RE_ESC = 117
- public static final NEWLINE = 118
- public static final ID_LETTER = 119
- public static final DIGIT = 120
- public static final HEXDIGIT = 121
+ public static final EACH = 12
+ public static final ENUM = 13
+ public static final EXTENDS = 14
+ public static final FALSE = 15
+ public static final FINAL = 16
+ public static final FINALLY = 17
+ public static final FOR = 18
+ public static final FUNCTION = 19
+ public static final GET = 20
+ public static final IF = 21
+ public static final IMPORT = 22
+ public static final IMPLEMENTS = 23
+ public static final IN = 24
+ public static final INTERFACE = 25
+ public static final INSTANCEOF = 26
+ public static final NEW = 27
+ public static final NOT = 28
+ public static final NULL = 29
+ public static final RETURN = 30
+ public static final PUBLIC = 31
+ public static final PROTECTED = 32
+ public static final INTERNAL = 33
+ public static final OVERRIDE = 34
+ public static final PARTIAL = 35
+ public static final PRIVATE = 36
+ public static final SET = 37
+ public static final STATIC = 38
+ public static final SUPER = 39
+ public static final THIS = 40
+ public static final THROW = 41
+ public static final TRUE = 42
+ public static final TRY = 43
+ public static final TYPEOF = 44
+ public static final VAR = 45
+ public static final VIRTUAL = 46
+ public static final WHILE = 47
+ public static final YIELD = 48
+ public static final SWITCH = 49
+ public static final CASE = 50
+ public static final DEFAULT = 51
+ public static final INPLACE_DIVISION = 52
+ public static final INPLACE_ADD = 53
+ public static final INPLACE_SUBTRACT = 54
+ public static final INPLACE_MULTIPLY = 55
+ public static final SL_COMMENT = 56
+ public static final PRAGMA_ON = 57
+ public static final PRAGMA_OFF = 58
+ public static final ID = 59
+ public static final DOUBLE_QUOTED_STRING = 60
+ public static final LBRACE = 61
+ public static final RBRACE = 62
+ public static final LPAREN = 63
+ public static final RPAREN = 64
+ public static final DOT = 65
+ public static final COLON = 66
+ public static final COMMA = 67
+ public static final LBRACK = 68
+ public static final RBRACK = 69
+ public static final BITWISE_OR = 70
+ public static final INPLACE_BITWISE_OR = 71
+ public static final BITWISE_AND = 72
+ public static final BITWISE_XOR = 73
+ public static final INPLACE_BITWISE_AND = 74
+ public static final LOGICAL_OR = 75
+ public static final LOGICAL_AND = 76
+ public static final EOS = 77
+ public static final ASSIGN = 78
+ public static final INCREMENT = 79
+ public static final DECREMENT = 80
+ public static final ADD = 81
+ public static final SUBTRACT = 82
+ public static final MODULUS = 83
+ public static final MULTIPLY = 84
+ public static final EQUALITY = 85
+ public static final INEQUALITY = 86
+ public static final QUESTION_MARK = 87
+ public static final BITWISE_NOT = 88
+ public static final REFERENCE_EQUALITY = 89
+ public static final REFERENCE_INEQUALITY = 90
+ public static final LESS_THAN = 91
+ public static final LESS_THAN_OR_EQUAL = 92
+ public static final SHIFT_LEFT = 93
+ public static final INPLACE_SHIFT_LEFT = 94
+ public static final GREATER_THAN = 95
+ public static final GREATER_THAN_OR_EQUAL = 96
+ public static final SHIFT_RIGHT = 97
+ public static final INPLACE_SHIFT_RIGHT = 98
+ public static final AT = 99
+ public static final SCRIPT_ATTRIBUTE_MARKER = 100
+ public static final ASSEMBLY_ATTRIBUTE_MARKER = 101
+ public static final INPLACE_BITWISE_XOR = 102
+ public static final LOGICAL_NOT = 103
+ public static final DIVISION = 104
+ public static final RE_LITERAL = 105
+ public static final DOUBLE = 106
+ public static final INT = 107
+ public static final LONG = 108
+ public static final SINGLE_QUOTED_STRING = 109
+ public static final DOUBLE_SUFFIX = 110
+ public static final EXPONENT = 111
+ public static final PRAGMA_WHITE_SPACE = 112
+ public static final WHITE_SPACE = 113
+ public static final DQS_ESC = 114
+ public static final SQS_ESC = 115
+ public static final SESC = 116
+ public static final ML_COMMENT = 117
+ public static final RE_CHAR = 118
+ public static final RE_ESC = 119
+ public static final NEWLINE = 120
+ public static final ID_LETTER = 121
+ public static final DIGIT = 122
+ public static final HEXDIGIT = 123
property PreserveComments = false
@@ -173,102 +175,104 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
caseSensitiveLiterals = true
setCaseSensitive(true)
literals = Hashtable(100, 0.4, null, Comparer.Default)
- literals.Add(",", 65)
- literals.Add("public", 29)
- literals.Add("a string", 58)
- literals.Add("an identifier", 57)
- literals.Add("]", 67)
- literals.Add("case", 48)
+ literals.Add(",", 67)
+ literals.Add("public", 31)
+ literals.Add("a string", 60)
+ literals.Add("an identifier", 59)
+ literals.Add("]", 69)
+ literals.Add("case", 50)
literals.Add("break", 5)
- literals.Add("while", 45)
- literals.Add("new", 26)
- literals.Add("||", 73)
- literals.Add("+", 79)
- literals.Add("instanceof", 25)
- literals.Add("implements", 22)
- literals.Add("*", 82)
- literals.Add("|=", 69)
- literals.Add("typeof", 42)
- literals.Add("@assembly", 99)
- literals.Add("[", 66)
- literals.Add(">>=", 96)
- literals.Add("return", 28)
- literals.Add("throw", 39)
- literals.Add("var", 43)
- literals.Add(")", 62)
- literals.Add("==", 83)
- literals.Add("null", 27)
- literals.Add("protected", 30)
- literals.Add("pragma off", 56)
- literals.Add("@script", 98)
+ literals.Add("while", 47)
+ literals.Add("new", 27)
+ literals.Add("||", 75)
+ literals.Add("+", 81)
+ literals.Add("instanceof", 26)
+ literals.Add("implements", 23)
+ literals.Add("*", 84)
+ literals.Add("|=", 71)
+ literals.Add("typeof", 44)
+ literals.Add("@assembly", 101)
+ literals.Add("[", 68)
+ literals.Add(">>=", 98)
+ literals.Add("not", 28)
+ literals.Add("return", 30)
+ literals.Add("throw", 41)
+ literals.Add("var", 45)
+ literals.Add(")", 64)
+ literals.Add("==", 85)
+ literals.Add("null", 29)
+ literals.Add("protected", 32)
+ literals.Add("pragma off", 58)
+ literals.Add("@script", 100)
literals.Add("class", 8)
- literals.Add("(", 61)
+ literals.Add("(", 63)
literals.Add("do", 10)
- literals.Add("~", 86)
- literals.Add("function", 18)
- literals.Add("/=", 50)
- literals.Add("super", 37)
- literals.Add("@", 97)
- literals.Add("-=", 52)
- literals.Add("set", 35)
- literals.Add("+=", 51)
- literals.Add("!==", 88)
- literals.Add("}", 60)
- literals.Add("interface", 24)
- literals.Add("?", 85)
- literals.Add("&", 70)
- literals.Add("internal", 31)
- literals.Add("final", 15)
- literals.Add("yield", 46)
- literals.Add("!=", 84)
- literals.Add("//", 54)
- literals.Add("===", 87)
- literals.Add("if", 20)
- literals.Add("|", 68)
- literals.Add("override", 32)
- literals.Add(">", 93)
+ literals.Add("~", 88)
+ literals.Add("function", 19)
+ literals.Add("/=", 52)
+ literals.Add("super", 39)
+ literals.Add("each", 12)
+ literals.Add("@", 99)
+ literals.Add("-=", 54)
+ literals.Add("set", 37)
+ literals.Add("+=", 53)
+ literals.Add("!==", 90)
+ literals.Add("}", 62)
+ literals.Add("interface", 25)
+ literals.Add("?", 87)
+ literals.Add("&", 72)
+ literals.Add("internal", 33)
+ literals.Add("final", 16)
+ literals.Add("yield", 48)
+ literals.Add("!=", 86)
+ literals.Add("//", 56)
+ literals.Add("===", 89)
+ literals.Add("if", 21)
+ literals.Add("|", 70)
+ literals.Add("override", 34)
+ literals.Add(">", 95)
literals.Add("as", 4)
- literals.Add("%", 81)
+ literals.Add("%", 83)
literals.Add("catch", 7)
- literals.Add("try", 41)
- literals.Add("{", 59)
- literals.Add("=", 76)
- literals.Add("enum", 12)
- literals.Add("for", 17)
- literals.Add(">>", 95)
- literals.Add("extends", 13)
- literals.Add("private", 34)
- literals.Add("default", 49)
- literals.Add("--", 78)
- literals.Add("<", 89)
- literals.Add("false", 14)
- literals.Add("this", 38)
- literals.Add("static", 36)
- literals.Add(">=", 94)
- literals.Add("<=", 90)
- literals.Add("partial", 33)
- literals.Add(";", 75)
- literals.Add("get", 19)
- literals.Add("<<=", 92)
+ literals.Add("try", 43)
+ literals.Add("{", 61)
+ literals.Add("=", 78)
+ literals.Add("enum", 13)
+ literals.Add("for", 18)
+ literals.Add(">>", 97)
+ literals.Add("extends", 14)
+ literals.Add("private", 36)
+ literals.Add("default", 51)
+ literals.Add("--", 80)
+ literals.Add("<", 91)
+ literals.Add("false", 15)
+ literals.Add("this", 40)
+ literals.Add("static", 38)
+ literals.Add(">=", 96)
+ literals.Add("<=", 92)
+ literals.Add("partial", 35)
+ literals.Add(";", 77)
+ literals.Add("get", 20)
+ literals.Add("<<=", 94)
literals.Add("continue", 9)
- literals.Add("&&", 74)
+ literals.Add("&&", 76)
literals.Add("cast", 6)
- literals.Add("<<", 91)
- literals.Add("pragma on", 55)
- literals.Add(".", 63)
- literals.Add("finally", 16)
+ literals.Add("<<", 93)
+ literals.Add("pragma on", 57)
+ literals.Add(".", 65)
+ literals.Add("finally", 17)
literals.Add("else", 11)
- literals.Add("import", 21)
- literals.Add("++", 77)
- literals.Add(":", 64)
- literals.Add("in", 23)
- literals.Add("switch", 47)
- literals.Add("true", 40)
- literals.Add("-", 80)
- literals.Add("*=", 53)
- literals.Add("virtual", 44)
- literals.Add("^", 71)
- literals.Add("&=", 72)
+ literals.Add("import", 22)
+ literals.Add("++", 79)
+ literals.Add(":", 66)
+ literals.Add("in", 24)
+ literals.Add("switch", 49)
+ literals.Add("true", 42)
+ literals.Add("-", 82)
+ literals.Add("*=", 55)
+ literals.Add("virtual", 46)
+ literals.Add("^", 73)
+ literals.Add("&=", 74)
override def nextToken() as IToken:
theRetToken as IToken
@@ -494,7 +498,7 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
mMULTIPLY(true)
theRetToken = returnToken_
elif ((cached_LA1==char('!')) and (true)): // line 2102
- mNOT(true)
+ mLOGICAL_NOT(true)
theRetToken = returnToken_
elif ((cached_LA1==char('<')) and (true)): // line 2102
mLESS_THAN(true)
@@ -594,8 +598,8 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
): // 1827
mDIGIT(false)
else: // line 1969
- goto _loop327_breakloop
- :_loop327_breakloop
+ goto _loop332_breakloop
+ :_loop332_breakloop
_ttype = testLiteralsTable(_ttype)
if (_createToken and (_token is null) and (_ttype != Token.SKIP)):
_token = makeToken(_ttype)
@@ -688,17 +692,17 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
if ((cached_LA1==char('0')) and (cached_LA2==char('x'))):
match("0x")
- _cnt331 as int = 0
+ _cnt336 as int = 0
while true:
if ((tokenSet_0_.member(cast(int, cached_LA1)))):
mHEXDIGIT(false)
else:
- if (_cnt331 >= 1):
- goto _loop331_breakloop
+ if (_cnt336 >= 1):
+ goto _loop336_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt331
- :_loop331_breakloop
+ ++_cnt336
+ :_loop336_breakloop
if ((cached_LA1==char('L') or cached_LA1==char('l'))):
_givenValue = cached_LA1
if ((_givenValue == char('l'))): // 1831
@@ -712,17 +716,17 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
else: // line 2053
pass // 947
elif ((((cached_LA1 >= char('0')) and (cached_LA1 <= char('9')))) and (true)): // line 2102
- _cnt335 as int = 0
+ _cnt340 as int = 0
while true:
if ((((cached_LA1 >= char('0')) and (cached_LA1 <= char('9'))))):
mDIGIT(false)
else:
- if (_cnt335 >= 1):
- goto _loop335_breakloop
+ if (_cnt340 >= 1):
+ goto _loop340_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt335
- :_loop335_breakloop
+ ++_cnt340
+ :_loop340_breakloop
_givenValue = cached_LA1
if ((_givenValue == char('L'))
or (_givenValue ==char('l'))
@@ -818,17 +822,17 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
_ttype as int; _token as IToken; _begin = text.Length;
_ttype = DOUBLE_SUFFIX
- _cnt344 as int = 0
+ _cnt349 as int = 0
while true:
if ((((cached_LA1 >= char('0')) and (cached_LA1 <= char('9'))))):
mDIGIT(false)
else:
- if (_cnt344 >= 1):
- goto _loop344_breakloop
+ if (_cnt349 >= 1):
+ goto _loop349_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt344
- :_loop344_breakloop
+ ++_cnt349
+ :_loop349_breakloop
if ((cached_LA1==char('E') or cached_LA1==char('e'))):
mEXPONENT(false)
else: // line 2053
@@ -879,17 +883,17 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
pass // 947
else: // line 1969
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- _cnt351 as int = 0
+ _cnt356 as int = 0
while true:
if ((((cached_LA1 >= char('0')) and (cached_LA1 <= char('9'))))):
mDIGIT(false)
else:
- if (_cnt351 >= 1):
- goto _loop351_breakloop
+ if (_cnt356 >= 1):
+ goto _loop356_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt351
- :_loop351_breakloop
+ ++_cnt356
+ :_loop356_breakloop
if (_createToken and (_token is null) and (_ttype != Token.SKIP)):
_token = makeToken(_ttype)
_token.setText(text.ToString(_begin, text.Length-_begin))
@@ -1129,31 +1133,31 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
_saveIndex = text.Length
match("#pragma")
text.Length = _saveIndex
- _cnt375 as int = 0
+ _cnt380 as int = 0
while true:
if ((cached_LA1==char('\t') or cached_LA1==char(' '))):
mPRAGMA_WHITE_SPACE(false)
else:
- if (_cnt375 >= 1):
- goto _loop375_breakloop
+ if (_cnt380 >= 1):
+ goto _loop380_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt375
- :_loop375_breakloop
+ ++_cnt380
+ :_loop380_breakloop
mID(true)
id = returnToken_
if ((cached_LA1==char('\t') or cached_LA1==char(' ')) and (cached_LA2==char('\t') or cached_LA2==char(' ') or cached_LA2==char('o')) and (LA(3)==char('\t') or LA(3)==char(' ') or LA(3)==char('f') or LA(3)==char('n') or LA(3)==char('o'))):
- _cnt378 as int = 0
+ _cnt383 as int = 0
while true:
if ((cached_LA1==char('\t') or cached_LA1==char(' '))):
mPRAGMA_WHITE_SPACE(false)
else:
- if (_cnt378 >= 1):
- goto _loop378_breakloop
+ if (_cnt383 >= 1):
+ goto _loop383_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt378
- :_loop378_breakloop
+ ++_cnt383
+ :_loop383_breakloop
if ((cached_LA1==char('o')) and (cached_LA2==char('f'))):
_saveIndex = text.Length
match("off")
@@ -1174,8 +1178,8 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
if ((cached_LA1==char('\t') or cached_LA1==char(' '))):
mPRAGMA_WHITE_SPACE(false)
else:
- goto _loop381_breakloop
- :_loop381_breakloop
+ goto _loop386_breakloop
+ :_loop386_breakloop
_saveIndex = text.Length
mNEWLINE(false)
text.Length = _saveIndex
@@ -1306,9 +1310,9 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
_token.setText(text.ToString(_begin, text.Length-_begin))
returnToken_ = _token
- public def mNOT(_createToken as bool) as void: //throws RecognitionException, CharStreamException, TokenStreamException
+ public def mLOGICAL_NOT(_createToken as bool) as void: //throws RecognitionException, CharStreamException, TokenStreamException
_ttype as int; _token as IToken; _begin = text.Length;
- _ttype = NOT
+ _ttype = LOGICAL_NOT
match('!')
if (_createToken and (_token is null) and (_ttype != Token.SKIP)):
@@ -1450,18 +1454,18 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
_ttype as int; _token as IToken; _begin = text.Length;
_ttype = DIVISION
- synPredMatched408 as bool = false
+ synPredMatched413 as bool = false
if ((cached_LA1==char('/')) and (cached_LA2==char('*'))):
- _m408 as int = mark()
- synPredMatched408 = true
+ _m413 as int = mark()
+ synPredMatched413 = true
++inputState.guessing
try:
match("/*")
except x as RecognitionException:
- synPredMatched408 = false
- rewind(_m408)
+ synPredMatched413 = false
+ rewind(_m413)
--inputState.guessing
- if synPredMatched408:
+ if synPredMatched413:
mML_COMMENT(false)
if 0 == inputState.guessing:
if not PreserveComments:
@@ -1475,8 +1479,8 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
if ((tokenSet_1_.member(cast(int, cached_LA1)))):
match(tokenSet_1_)
else:
- goto _loop413_breakloop
- :_loop413_breakloop
+ goto _loop418_breakloop
+ :_loop418_breakloop
if 0 == inputState.guessing:
if PreserveComments:
_ttype = SL_COMMENT
@@ -1508,8 +1512,8 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
elif ((tokenSet_2_.member(cast(int, cached_LA1)))): // line 2102
match(tokenSet_2_)
else:
- goto _loop442_breakloop
- :_loop442_breakloop
+ goto _loop447_breakloop
+ :_loop447_breakloop
match("*/")
if (_createToken and (_token is null) and (_ttype != Token.SKIP)):
_token = makeToken(_ttype)
@@ -1520,7 +1524,7 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
_ttype as int; _token as IToken; _begin = text.Length;
_ttype = WHITE_SPACE
- _cnt417 as int = 0
+ _cnt422 as int = 0
while true:
_givenValue = cached_LA1
if ((_givenValue == char(' '))): // 1831
@@ -1534,12 +1538,12 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
): // 1827
mNEWLINE(false)
else: // line 1969
- if (_cnt417 >= 1):
- goto _loop417_breakloop
+ if (_cnt422 >= 1):
+ goto _loop422_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt417
- :_loop417_breakloop
+ ++_cnt422
+ :_loop422_breakloop
if 0 == inputState.guessing:
_ttype = Token.SKIP;
if (_createToken and (_token is null) and (_ttype != Token.SKIP)):
@@ -1560,8 +1564,8 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
elif ((tokenSet_3_.member(cast(int, cached_LA1)))): // line 2102
match(tokenSet_3_)
else:
- goto _loop421_breakloop
- :_loop421_breakloop
+ goto _loop426_breakloop
+ :_loop426_breakloop
_saveIndex = text.Length
match('"')
text.Length = _saveIndex
@@ -1610,8 +1614,8 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
elif ((tokenSet_4_.member(cast(int, cached_LA1)))): // line 2102
match(tokenSet_4_)
else:
- goto _loop425_breakloop
- :_loop425_breakloop
+ goto _loop430_breakloop
+ :_loop430_breakloop
_saveIndex = text.Length
match('\'')
text.Length = _saveIndex
@@ -1712,17 +1716,17 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
_ttype = RE_LITERAL
match('/')
- _cnt445 as int = 0
+ _cnt450 as int = 0
while true:
if ((tokenSet_5_.member(cast(int, cached_LA1)))):
mRE_CHAR(false)
else:
- if (_cnt445 >= 1):
- goto _loop445_breakloop
+ if (_cnt450 >= 1):
+ goto _loop450_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt445
- :_loop445_breakloop
+ ++_cnt450
+ :_loop450_breakloop
match('/')
if (_createToken and (_token is null) and (_ttype != Token.SKIP)):
_token = makeToken(_ttype)
@@ -1780,17 +1784,17 @@ class UnityScriptLexer(antlr.CharScanner, TokenStream):
or (_givenValue ==char('8'))
or (_givenValue ==char('9'))
): // 1827
- _cnt451 as int = 0
+ _cnt456 as int = 0
while true:
if ((((cached_LA1 >= char('0')) and (cached_LA1 <= char('9')))) and (tokenSet_7_.member(cast(int, cached_LA2))) and (true)):
mDIGIT(false)
else:
- if (_cnt451 >= 1):
- goto _loop451_breakloop
+ if (_cnt456 >= 1):
+ goto _loop456_breakloop
else:
raise NoViableAltForCharException(cached_LA1, getFilename(), getLine(), getColumn())
- ++_cnt451
- :_loop451_breakloop
+ ++_cnt456
+ :_loop456_breakloop
elif ((_givenValue == char('x'))): // 1831
match('x')
mDIGIT(false)
1,053 src/UnityScript/Parser/UnityScriptParser.boo
View
@@ -38,116 +38,118 @@ partial class UnityScriptParser(antlr.LLkParser):
public static final CONTINUE = 9
public static final DO = 10
public static final ELSE = 11
- public static final ENUM = 12
- public static final EXTENDS = 13
- public static final FALSE = 14
- public static final FINAL = 15
- public static final FINALLY = 16
- public static final FOR = 17
- public static final FUNCTION = 18
- public static final GET = 19
- public static final IF = 20
- public static final IMPORT = 21
- public static final IMPLEMENTS = 22
- public static final IN = 23
- public static final INTERFACE = 24
- public static final INSTANCEOF = 25
- public static final NEW = 26
- public static final NULL = 27
- public static final RETURN = 28
- public static final PUBLIC = 29
- public static final PROTECTED = 30
- public static final INTERNAL = 31
- public static final OVERRIDE = 32
- public static final PARTIAL = 33
- public static final PRIVATE = 34
- public static final SET = 35
- public static final STATIC = 36
- public static final SUPER = 37
- public static final THIS = 38
- public static final THROW = 39
- public static final TRUE = 40
- public static final TRY = 41
- public static final TYPEOF = 42
- public static final VAR = 43
- public static final VIRTUAL = 44
- public static final WHILE = 45
- public static final YIELD = 46
- public static final SWITCH = 47
- public static final CASE = 48
- public static final DEFAULT = 49
- public static final INPLACE_DIVISION = 50
- public static final INPLACE_ADD = 51
- public static final INPLACE_SUBTRACT = 52
- public static final INPLACE_MULTIPLY = 53
- public static final SL_COMMENT = 54
- public static final PRAGMA_ON = 55
- public static final PRAGMA_OFF = 56
- public static final ID = 57
- public static final DOUBLE_QUOTED_STRING = 58
- public static final LBRACE = 59
- public static final RBRACE = 60
- public static final LPAREN = 61
- public static final RPAREN = 62
- public static final DOT = 63
- public static final COLON = 64
- public static final COMMA = 65
- public static final LBRACK = 66
- public static final RBRACK = 67
- public static final BITWISE_OR = 68
- public static final INPLACE_BITWISE_OR = 69
- public static final BITWISE_AND = 70
- public static final BITWISE_XOR = 71
- public static final INPLACE_BITWISE_AND = 72
- public static final LOGICAL_OR = 73
- public static final LOGICAL_AND = 74
- public static final EOS = 75
- public static final ASSIGN = 76
- public static final INCREMENT = 77
- public static final DECREMENT = 78
- public static final ADD = 79
- public static final SUBTRACT = 80
- public static final MODULUS = 81
- public static final MULTIPLY = 82
- public static final EQUALITY = 83
- public static final INEQUALITY = 84
- public static final QUESTION_MARK = 85
- public static final BITWISE_NOT = 86
- public static final REFERENCE_EQUALITY = 87
- public static final REFERENCE_INEQUALITY = 88
- public static final LESS_THAN = 89
- public static final LESS_THAN_OR_EQUAL = 90
- public static final SHIFT_LEFT = 91
- public static final INPLACE_SHIFT_LEFT = 92
- public static final GREATER_THAN = 93
- public static final GREATER_THAN_OR_EQUAL = 94
- public static final SHIFT_RIGHT = 95
- public static final INPLACE_SHIFT_RIGHT = 96
- public static final AT = 97
- public static final SCRIPT_ATTRIBUTE_MARKER = 98
- public static final ASSEMBLY_ATTRIBUTE_MARKER = 99
- public static final INPLACE_BITWISE_XOR = 100
- public static final NOT = 101
- public static final DIVISION = 102
- public static final RE_LITERAL = 103
- public static final DOUBLE = 104
- public static final INT = 105
- public static final LONG = 106
- public static final SINGLE_QUOTED_STRING = 107
- public static final DOUBLE_SUFFIX = 108
- public static final EXPONENT = 109
- public static final PRAGMA_WHITE_SPACE = 110
- public static final WHITE_SPACE = 111
- public static final DQS_ESC = 112
- public static final SQS_ESC = 113
- public static final SESC = 114
- public static final ML_COMMENT = 115
- public static final RE_CHAR = 116
- public static final RE_ESC = 117
- public static final NEWLINE = 118
- public static final ID_LETTER = 119
- public static final DIGIT = 120
- public static final HEXDIGIT = 121
+ public static final EACH = 12
+ public static final ENUM = 13
+ public static final EXTENDS = 14
+ public static final FALSE = 15
+ public static final FINAL = 16
+ public static final FINALLY = 17
+ public static final FOR = 18
+ public static final FUNCTION = 19
+ public static final GET = 20
+ public static final IF = 21
+ public static final IMPORT = 22
+ public static final IMPLEMENTS = 23
+ public static final IN = 24
+ public static final INTERFACE = 25
+ public static final INSTANCEOF = 26
+ public static final NEW = 27
+ public static final NOT = 28
+ public static final NULL = 29
+ public static final RETURN = 30
+ public static final PUBLIC = 31
+ public static final PROTECTED = 32
+ public static final INTERNAL = 33
+ public static final OVERRIDE = 34
+ public static final PARTIAL = 35
+ public static final PRIVATE = 36
+ public static final SET = 37
+ public static final STATIC = 38
+ public static final SUPER = 39
+ public static final THIS = 40
+ public static final THROW = 41
+ public static final TRUE = 42
+ public static final TRY = 43
+ public static final TYPEOF = 44
+ public static final VAR = 45
+ public static final VIRTUAL = 46
+ public static final WHILE = 47
+ public static final YIELD = 48
+ public static final SWITCH = 49
+ public static final CASE = 50
+ public static final DEFAULT = 51
+ public static final INPLACE_DIVISION = 52
+ public static final INPLACE_ADD = 53
+ public static final INPLACE_SUBTRACT = 54
+ public static final INPLACE_MULTIPLY = 55
+ public static final SL_COMMENT = 56
+ public static final PRAGMA_ON = 57
+ public static final PRAGMA_OFF = 58
+ public static final ID = 59
+ public static final DOUBLE_QUOTED_STRING = 60
+ public static final LBRACE = 61
+ public static final RBRACE = 62
+ public static final LPAREN = 63
+ public static final RPAREN = 64
+ public static final DOT = 65
+ public static final COLON = 66
+ public static final COMMA = 67
+ public static final LBRACK = 68
+ public static final RBRACK = 69
+ public static final BITWISE_OR = 70
+ public static final INPLACE_BITWISE_OR = 71
+ public static final BITWISE_AND = 72
+ public static final BITWISE_XOR = 73
+ public static final INPLACE_BITWISE_AND = 74
+ public static final LOGICAL_OR = 75
+ public static final LOGICAL_AND = 76
+ public static final EOS = 77
+ public static final ASSIGN = 78
+ public static final INCREMENT = 79
+ public static final DECREMENT = 80
+ public static final ADD = 81
+ public static final SUBTRACT = 82
+ public static final MODULUS = 83
+ public static final MULTIPLY = 84
+ public static final EQUALITY = 85
+ public static final INEQUALITY = 86
+ public static final QUESTION_MARK = 87
+ public static final BITWISE_NOT = 88
+ public static final REFERENCE_EQUALITY = 89
+ public static final REFERENCE_INEQUALITY = 90
+ public static final LESS_THAN = 91
+ public static final LESS_THAN_OR_EQUAL = 92
+ public static final SHIFT_LEFT = 93
+ public static final INPLACE_SHIFT_LEFT = 94
+ public static final GREATER_THAN = 95
+ public static final GREATER_THAN_OR_EQUAL = 96
+ public static final SHIFT_RIGHT = 97
+ public static final INPLACE_SHIFT_RIGHT = 98
+ public static final AT = 99
+ public static final SCRIPT_ATTRIBUTE_MARKER = 100
+ public static final ASSEMBLY_ATTRIBUTE_MARKER = 101
+ public static final INPLACE_BITWISE_XOR = 102
+ public static final LOGICAL_NOT = 103
+ public static final DIVISION = 104
+ public static final RE_LITERAL = 105
+ public static final DOUBLE = 106
+ public static final INT = 107
+ public static final LONG = 108
+ public static final SINGLE_QUOTED_STRING = 109
+ public static final DOUBLE_SUFFIX = 110
+ public static final EXPONENT = 111
+ public static final PRAGMA_WHITE_SPACE = 112
+ public static final WHITE_SPACE = 113
+ public static final DQS_ESC = 114
+ public static final SQS_ESC = 115
+ public static final SESC = 116
+ public static final ML_COMMENT = 117
+ public static final RE_CHAR = 118
+ public static final RE_ESC = 119
+ public static final NEWLINE = 120
+ public static final ID_LETTER = 121
+ public static final DIGIT = 122
+ public static final HEXDIGIT = 123
[property(CompilerContext)]
@@ -518,10 +520,10 @@ partial class UnityScriptParser(antlr.LLkParser):
--inputState.guessing
if synPredMatched27:
module_field(module)
- elif ((LA(1)==VAR) and (LA(2)==FINAL or LA(2)==INTERNAL or LA(2)==ID)): // line 2102
+ elif ((LA(1)==VAR) and (tokenSet_9_.member(cast(int, LA(2))))): // line 2102
declaration_statement(globals)
eos()
- elif ((tokenSet_9_.member(cast(int, LA(1)))) and (tokenSet_10_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_10_.member(cast(int, LA(1)))) and (tokenSet_11_.member(cast(int, LA(2))))): // line 2102
mod=module_member_modifiers()
_givenValue = LA(1)
if ((_givenValue == CLASS)
@@ -543,7 +545,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_11_)
+ recover(ex,tokenSet_12_)
else:
raise
@@ -554,7 +556,7 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
synPredMatched107 as bool = false
- if ((LA(1)==GET or LA(1)==SET or LA(1)==ID) and (tokenSet_12_.member(cast(int, LA(2))))):
+ if ((tokenSet_13_.member(cast(int, LA(1)))) and (tokenSet_14_.member(cast(int, LA(2))))):
_m107 as int = mark()
synPredMatched107 = true
++inputState.guessing
@@ -566,12 +568,12 @@ partial class UnityScriptParser(antlr.LLkParser):
--inputState.guessing
if synPredMatched107:
macro_application_block(b)
- elif ((tokenSet_13_.member(cast(int, LA(1)))) and (tokenSet_14_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_15_.member(cast(int, LA(1)))) and (tokenSet_16_.member(cast(int, LA(2))))): // line 2102
builtin_statement(b)
elif ((LA(1)==EOS)): // line 2102
_cnt109 as int = 0
while true:
- if ((LA(1)==EOS) and (tokenSet_15_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_17_.member(cast(int, LA(2))))):
match(EOS)
else:
if (_cnt109 >= 1):
@@ -585,7 +587,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -596,7 +598,7 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
synPredMatched13 as bool = false
- if ((LA(1)==ID) and (LA(2)==DOT or LA(2)==ASSIGN)):
+ if ((LA(1)==EACH or LA(1)==ID) and (LA(2)==DOT or LA(2)==ASSIGN)):
_m13 as int = mark()
synPredMatched13 = true
++inputState.guessing
@@ -613,7 +615,7 @@ partial class UnityScriptParser(antlr.LLkParser):
value=expression()
if 0 == inputState.guessing:
attr.NamedArguments.Add(ExpressionPair(name, value))
- elif ((tokenSet_12_.member(cast(int, LA(1)))) and (tokenSet_16_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_14_.member(cast(int, LA(1)))) and (tokenSet_18_.member(cast(int, LA(2))))): // line 2102
value=expression()
if 0 == inputState.guessing:
attr.Arguments.Add(value)
@@ -622,7 +624,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_17_)
+ recover(ex,tokenSet_19_)
else:
raise
@@ -637,12 +639,12 @@ partial class UnityScriptParser(antlr.LLkParser):
match(DOT)
e=member_reference_expression(e)
else:
- goto _loop207_breakloop
- :_loop207_breakloop
+ goto _loop211_breakloop
+ :_loop211_breakloop
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_18_)
+ recover(ex,tokenSet_20_)
else:
raise
return e
@@ -656,7 +658,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_19_)
+ recover(ex,tokenSet_21_)
else:
raise
return e
@@ -672,7 +674,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_20_)
+ recover(ex,tokenSet_22_)
else:
raise
@@ -684,10 +686,11 @@ partial class UnityScriptParser(antlr.LLkParser):
name=qname()
if 0 == inputState.guessing:
attr = Ast.Attribute(ToLexicalInfo(name), name.getText())
- if ((LA(1)==LPAREN) and (tokenSet_21_.member(cast(int, LA(2))))):
+ if ((LA(1)==LPAREN) and (tokenSet_23_.member(cast(int, LA(2))))):
match(LPAREN)
_givenValue = LA(1)
- if ((_givenValue == FALSE)
+ if ((_givenValue == EACH)
+ or (_givenValue ==FALSE)
or (_givenValue ==FUNCTION)
or (_givenValue ==NEW)
or (_givenValue ==NULL)
@@ -704,7 +707,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==DECREMENT)
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -724,14 +727,14 @@ partial class UnityScriptParser(antlr.LLkParser):
else: // line 1969
raise NoViableAltException(LT(1), getFilename())
match(RPAREN)
- elif ((tokenSet_22_.member(cast(int, LA(1)))) and (tokenSet_23_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_24_.member(cast(int, LA(1)))) and (tokenSet_25_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_22_)
+ recover(ex,tokenSet_24_)
else:
raise
return attr
@@ -765,7 +768,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_24_)
+ recover(ex,tokenSet_26_)
else:
raise
return id
@@ -814,7 +817,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_25_)
+ recover(ex,tokenSet_27_)
else:
raise
return m
@@ -832,7 +835,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_11_)
+ recover(ex,tokenSet_12_)
else:
raise
@@ -854,6 +857,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==CONTINUE)
or (_givenValue ==DO)
or (_givenValue ==ELSE)
+ or (_givenValue ==EACH)
or (_givenValue ==ENUM)
or (_givenValue ==FALSE)
or (_givenValue ==FINAL)
@@ -898,7 +902,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
or (_givenValue ==AT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -914,7 +918,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -924,10 +928,10 @@ partial class UnityScriptParser(antlr.LLkParser):
t as IToken = null
try: // for error handling
- if ((LA(1)==EOS) and (tokenSet_26_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_28_.member(cast(int, LA(2))))):
_cnt42 as int = 0
while true:
- if ((LA(1)==EOS) and (tokenSet_26_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_28_.member(cast(int, LA(2))))):
t = LT(1)
match(EOS)
if 0 == inputState.guessing:
@@ -939,7 +943,7 @@ partial class UnityScriptParser(antlr.LLkParser):
raise NoViableAltException(LT(1), getFilename())
++_cnt42
:_loop42_breakloop
- elif ((tokenSet_26_.member(cast(int, LA(1)))) and (tokenSet_27_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_28_.member(cast(int, LA(1)))) and (tokenSet_29_.member(cast(int, LA(2))))): // line 2102
if 0 == inputState.guessing:
SemicolonExpected()
else:
@@ -947,7 +951,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_26_)
+ recover(ex,tokenSet_28_)
else:
raise
return firstEOS
@@ -1007,7 +1011,7 @@ partial class UnityScriptParser(antlr.LLkParser):
BaseTypeAnnotations.AnnotateImplements(typeRef)
match(LBRACE)
while true:
- if ((tokenSet_28_.member(cast(int, LA(1))))):
+ if ((tokenSet_30_.member(cast(int, LA(1))))):
if 0 == inputState.guessing:
mod = TypeMemberModifiers.None
_givenValue = LA(1)
@@ -1032,9 +1036,9 @@ partial class UnityScriptParser(antlr.LLkParser):
pass // 947
else: // line 1969
raise NoViableAltException(LT(1), getFilename())
- if ((tokenSet_29_.member(cast(int, LA(1)))) and (tokenSet_30_.member(cast(int, LA(2))))):
+ if ((tokenSet_31_.member(cast(int, LA(1)))) and (tokenSet_32_.member(cast(int, LA(2))))):
mod=member_modifiers()
- elif ((tokenSet_25_.member(cast(int, LA(1)))) and (tokenSet_31_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_27_.member(cast(int, LA(1)))) and (tokenSet_33_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
@@ -1063,7 +1067,7 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
SetEndSourceLocation(cd, rbrace)
while true:
- if ((LA(1)==EOS) and (tokenSet_32_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_34_.member(cast(int, LA(2))))):
match(EOS)
else:
goto _loop59_breakloop
@@ -1071,7 +1075,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_32_)
+ recover(ex,tokenSet_34_)
else:
raise
return member
@@ -1120,7 +1124,7 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
SetEndSourceLocation(td, rbrace)
while true:
- if ((LA(1)==EOS) and (tokenSet_32_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_34_.member(cast(int, LA(2))))):
match(EOS)
else:
goto _loop66_breakloop
@@ -1128,7 +1132,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_32_)
+ recover(ex,tokenSet_34_)
else:
raise
return member
@@ -1178,7 +1182,7 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
SetEndSourceLocation(ed, rbrace)
while true:
- if ((LA(1)==EOS) and (tokenSet_32_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_34_.member(cast(int, LA(2))))):
match(EOS)
else:
goto _loop79_breakloop
@@ -1186,7 +1190,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_32_)
+ recover(ex,tokenSet_34_)
else:
raise
return member
@@ -1208,7 +1212,8 @@ partial class UnityScriptParser(antlr.LLkParser):
elif ((_givenValue == SET)): // 1831
setter = LT(1)
match(SET)
- elif ((_givenValue == FINAL)
+ elif ((_givenValue == EACH)
+ or (_givenValue ==FINAL)
or (_givenValue ==INTERNAL)
or (_givenValue ==ID)
): // 1827
@@ -1224,7 +1229,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_32_)
+ recover(ex,tokenSet_34_)
else:
raise
return member
@@ -1247,6 +1252,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==CLASS)
or (_givenValue ==CONTINUE)
or (_givenValue ==DO)
+ or (_givenValue ==EACH)
or (_givenValue ==ENUM)
or (_givenValue ==FALSE)
or (_givenValue ==FINAL)
@@ -1290,7 +1296,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
or (_givenValue ==AT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -1309,6 +1315,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==CLASS)
or (_givenValue ==CONTINUE)
or (_givenValue ==DO)
+ or (_givenValue ==EACH)
or (_givenValue ==ENUM)
or (_givenValue ==FALSE)
or (_givenValue ==FINAL)
@@ -1351,7 +1358,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
or (_givenValue ==AT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -1373,7 +1380,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_32_)
+ recover(ex,tokenSet_34_)
else:
raise
return member
@@ -1430,7 +1437,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_25_)
+ recover(ex,tokenSet_27_)
else:
raise
return m
@@ -1458,19 +1465,19 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
++rank
else:
- goto _loop176_breakloop
- :_loop176_breakloop
+ goto _loop179_breakloop
+ :_loop179_breakloop
match(RBRACK)
if 0 == inputState.guessing:
tr = ArrayTypeReference(tr.LexicalInfo, tr, IntegerLiteralExpression(ToLexicalInfo(lbrack), rank))
- elif ((tokenSet_33_.member(cast(int, LA(1)))) and (tokenSet_24_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_35_.member(cast(int, LA(1)))) and (tokenSet_26_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_33_)
+ recover(ex,tokenSet_35_)
else:
raise
return tr
@@ -1491,12 +1498,12 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
typeReferences.Add(tr)
else:
- goto _loop192_breakloop
- :_loop192_breakloop
+ goto _loop195_breakloop
+ :_loop195_breakloop
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_34_)
+ recover(ex,tokenSet_36_)
else:
raise
@@ -1516,7 +1523,8 @@ partial class UnityScriptParser(antlr.LLkParser):
elif ((_givenValue == SET)): // 1831
setter = LT(1)
match(SET)
- elif ((_givenValue == FINAL)
+ elif ((_givenValue == EACH)
+ or (_givenValue ==FINAL)
or (_givenValue ==INTERNAL)
or (_givenValue ==ID)
): // 1827
@@ -1528,7 +1536,8 @@ partial class UnityScriptParser(antlr.LLkParser):
function = AddFunctionTo(parent, memberName, getter, setter)
match(LPAREN)
_givenValue = LA(1)
- if ((_givenValue == FINAL)
+ if ((_givenValue == EACH)
+ or (_givenValue ==FINAL)
or (_givenValue ==INTERNAL)
or (_givenValue ==ID)
or (_givenValue ==AT)
@@ -1564,7 +1573,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_35_)
+ recover(ex,tokenSet_37_)
else:
raise
@@ -1574,6 +1583,7 @@ partial class UnityScriptParser(antlr.LLkParser):
name as IToken = null
f as IToken = null
i as IToken = null
+ e as IToken = null
try: // for error handling
_givenValue = LA(1)
@@ -1592,12 +1602,17 @@ partial class UnityScriptParser(antlr.LLkParser):
match(INTERNAL)
if 0 == inputState.guessing:
token = i; KeywordCannotBeUsedAsAnIdentifier(token);
+ elif ((_givenValue == EACH)): // 1831
+ e = LT(1)
+ match(EACH)
+ if 0 == inputState.guessing:
+ token = e;
else: // line 1969
raise NoViableAltException(LT(1), getFilename())
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_36_)
+ recover(ex,tokenSet_38_)
else:
raise
return token
@@ -1619,7 +1634,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_37_)
+ recover(ex,tokenSet_39_)
else:
raise
@@ -1656,7 +1671,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_38_)
+ recover(ex,tokenSet_40_)
else:
raise
@@ -1684,7 +1699,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_19_)
+ recover(ex,tokenSet_21_)
else:
raise
return e
@@ -1697,7 +1712,8 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
match(LPAREN)
_givenValue = LA(1)
- if ((_givenValue == FINAL)
+ if ((_givenValue == EACH)
+ or (_givenValue ==FINAL)
or (_givenValue ==INTERNAL)
or (_givenValue ==ID)
or (_givenValue ==AT)
@@ -1724,7 +1740,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_32_)
+ recover(ex,tokenSet_34_)
else:
raise
@@ -1736,7 +1752,7 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
block(b)
while true:
- if ((LA(1)==EOS) and (tokenSet_39_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_41_.member(cast(int, LA(2))))):
match(EOS)
else:
goto _loop101_breakloop
@@ -1744,7 +1760,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_39_)
+ recover(ex,tokenSet_41_)
else:
raise
@@ -1757,7 +1773,8 @@ partial class UnityScriptParser(antlr.LLkParser):
_givenValue = LA(1)
if ((_givenValue == AT)): // 1831
attributes()
- elif ((_givenValue == FINAL)
+ elif ((_givenValue == EACH)
+ or (_givenValue ==FINAL)
or (_givenValue ==INTERNAL)
or (_givenValue ==ID)
): // 1827
@@ -1782,7 +1799,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_17_)
+ recover(ex,tokenSet_19_)
else:
raise
@@ -1792,16 +1809,16 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
- if ((LA(1)==LBRACE) and (tokenSet_40_.member(cast(int, LA(2))))):
+ if ((LA(1)==LBRACE) and (tokenSet_42_.member(cast(int, LA(2))))):
compound_statement(b)
- elif ((tokenSet_2_.member(cast(int, LA(1)))) and (tokenSet_14_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_2_.member(cast(int, LA(1)))) and (tokenSet_16_.member(cast(int, LA(2))))): // line 2102
statement(b)
else:
raise NoViableAltException(LT(1), getFilename())
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -1826,7 +1843,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_19_)
+ recover(ex,tokenSet_21_)
else:
raise
@@ -1834,10 +1851,10 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
- if ((LA(1)==GET or LA(1)==SET or LA(1)==ID) and (LA(2)==LBRACE)):
+ if ((tokenSet_13_.member(cast(int, LA(1)))) and (LA(2)==LBRACE)):
member()
match(LBRACE)
- elif ((LA(1)==GET or LA(1)==SET or LA(1)==ID) and (tokenSet_12_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_13_.member(cast(int, LA(1)))) and (tokenSet_14_.member(cast(int, LA(2))))): // line 2102
member()
expression_list(null)
match(LBRACE)
@@ -1860,20 +1877,20 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
macroName=member()
- synPredMatched145 as bool = false
- if ((LA(1)==LBRACE) and (tokenSet_40_.member(cast(int, LA(2))))):
- _m145 as int = mark()
- synPredMatched145 = true
+ synPredMatched148 as bool = false
+ if ((LA(1)==LBRACE) and (tokenSet_42_.member(cast(int, LA(2))))):
+ _m148 as int = mark()
+ synPredMatched148 = true
++inputState.guessing
try:
match(LBRACE)
except x as RecognitionException:
- synPredMatched145 = false
- rewind(_m145)
+ synPredMatched148 = false
+ rewind(_m148)
--inputState.guessing
- if synPredMatched145:
+ if synPredMatched148:
compound_statement(b)
- elif ((tokenSet_12_.member(cast(int, LA(1)))) and (tokenSet_41_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_14_.member(cast(int, LA(1)))) and (tokenSet_43_.member(cast(int, LA(2))))): // line 2102
expression_list(args)
compound_statement(b)
else:
@@ -1885,7 +1902,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -1920,6 +1937,7 @@ partial class UnityScriptParser(antlr.LLkParser):
raise NoViableAltException(LT(1), getFilename())
elif ((_givenValue == BREAK)
or (_givenValue ==CONTINUE)
+ or (_givenValue ==EACH)
or (_givenValue ==FALSE)
or (_givenValue ==FUNCTION)
or (_givenValue ==NEW)
@@ -1941,7 +1959,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==DECREMENT)
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -1949,7 +1967,8 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==SINGLE_QUOTED_STRING)
): // 1827
_givenValue = LA(1)
- if ((_givenValue == FALSE)
+ if ((_givenValue == EACH)
+ or (_givenValue ==FALSE)
or (_givenValue ==FUNCTION)
or (_givenValue ==NEW)
or (_givenValue ==NULL)
@@ -1966,7 +1985,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==DECREMENT)
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -1994,7 +2013,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2024,7 +2043,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2049,7 +2068,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2062,40 +2081,49 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
f = LT(1)
match(FOR)
- match(LPAREN)
- synPredMatched129 as bool = false
- if ((tokenSet_42_.member(cast(int, LA(1)))) and (tokenSet_43_.member(cast(int, LA(2))))):
- _m129 as int = mark()
- synPredMatched129 = true
- ++inputState.guessing
- try:
- _givenValue = LA(1)
- if ((_givenValue == FINAL)
- or (_givenValue ==INTERNAL)
- or (_givenValue ==ID)
- ): // 1827
- identifier()
- elif ((_givenValue == VAR)): // 1831
- declaration()
- else: // line 1969
- raise NoViableAltException(LT(1), getFilename())
- match(IN)
- except x as RecognitionException:
- synPredMatched129 = false
- rewind(_m129)
- --inputState.guessing
- if synPredMatched129:
+ _givenValue = LA(1)
+ if ((_givenValue == EACH)): // 1831
+ match(EACH)
+ match(LPAREN)
stmt=for_in(container)
- elif ((tokenSet_44_.member(cast(int, LA(1)))) and (tokenSet_45_.member(cast(int, LA(2))))): // line 2102
- stmt=for_c(container)
- else:
- raise NoViableAltException(LT(1), getFilename())
+ elif ((_givenValue == LPAREN)): // 1831
+ match(LPAREN)
+ synPredMatched132 as bool = false
+ if ((tokenSet_44_.member(cast(int, LA(1)))) and (tokenSet_45_.member(cast(int, LA(2))))):
+ _m132 as int = mark()
+ synPredMatched132 = true
+ ++inputState.guessing
+ try:
+ _givenValue = LA(1)
+ if ((_givenValue == EACH)
+ or (_givenValue ==FINAL)
+ or (_givenValue ==INTERNAL)
+ or (_givenValue ==ID)
+ ): // 1827
+ identifier()
+ elif ((_givenValue == VAR)): // 1831
+ declaration()
+ else: // line 1969
+ raise NoViableAltException(LT(1), getFilename())
+ match(IN)
+ except x as RecognitionException:
+ synPredMatched132 = false
+ rewind(_m132)
+ --inputState.guessing
+ if synPredMatched132:
+ stmt=for_in(container)
+ elif ((tokenSet_46_.member(cast(int, LA(1)))) and (tokenSet_47_.member(cast(int, LA(2))))): // line 2102
+ stmt=for_c(container)
+ else:
+ raise NoViableAltException(LT(1), getFilename())
+ else: // line 1969
+ raise NoViableAltException(LT(1), getFilename())
if 0 == inputState.guessing:
- stmt.LexicalInfo = ToLexicalInfo(f) if stmt is not null
+ stmt.LexicalInfo = ToLexicalInfo(f) if stmt is not null
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2121,14 +2149,14 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
b = s.FalseBlock = Block(ToLexicalInfo(et))
compound_or_single_stmt(b)
- elif ((tokenSet_15_.member(cast(int, LA(1)))) and (tokenSet_19_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_17_.member(cast(int, LA(1)))) and (tokenSet_21_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2174,18 +2202,18 @@ partial class UnityScriptParser(antlr.LLkParser):
tr = null
compound_or_single_stmt(b)
else:
- goto _loop164_breakloop
- :_loop164_breakloop
+ goto _loop167_breakloop
+ :_loop167_breakloop
if ((LA(1)==FINALLY) and (tokenSet_2_.member(cast(int, LA(2))))):
finally_block(s)
- elif ((tokenSet_15_.member(cast(int, LA(1)))) and (tokenSet_19_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_17_.member(cast(int, LA(1)))) and (tokenSet_21_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2228,22 +2256,22 @@ partial class UnityScriptParser(antlr.LLkParser):
if 0 == inputState.guessing:
item.Arguments.Add(e);
else:
- goto _loop152_breakloop
- :_loop152_breakloop
- _cnt154 as int = 0
+ goto _loop155_breakloop
+ :_loop155_breakloop
+ _cnt157 as int = 0
while true:
if ((tokenSet_2_.member(cast(int, LA(1))))):
statement(itemBlock)
else:
- if (_cnt154 >= 1):
- goto _loop154_breakloop
+ if (_cnt157 >= 1):
+ goto _loop157_breakloop
else:
raise NoViableAltException(LT(1), getFilename())
- ++_cnt154
- :_loop154_breakloop
+ ++_cnt157
+ :_loop157_breakloop
else:
- goto _loop155_breakloop
- :_loop155_breakloop
+ goto _loop158_breakloop
+ :_loop158_breakloop
_givenValue = LA(1)
if ((_givenValue == DEFAULT)): // 1831
d = LT(1)
@@ -2253,32 +2281,32 @@ partial class UnityScriptParser(antlr.LLkParser):
item = MacroStatement(ToLexicalInfo(d), Name: d.getText())
itemBlock = item.Body
switchBlock.Add(item)
- _cnt158 as int = 0
+ _cnt161 as int = 0
while true:
if ((tokenSet_2_.member(cast(int, LA(1))))):
statement(itemBlock)
else:
- if (_cnt158 >= 1):
- goto _loop158_breakloop
+ if (_cnt161 >= 1):
+ goto _loop161_breakloop
else:
raise NoViableAltException(LT(1), getFilename())
- ++_cnt158
- :_loop158_breakloop
+ ++_cnt161
+ :_loop161_breakloop
elif ((_givenValue == RBRACE)): // 1831
pass // 947
else: // line 1969
raise NoViableAltException(LT(1), getFilename())
match(RBRACE)
while true:
- if ((LA(1)==EOS) and (tokenSet_15_.member(cast(int, LA(2))))):
+ if ((LA(1)==EOS) and (tokenSet_17_.member(cast(int, LA(2))))):
match(EOS)
else:
- goto _loop160_breakloop
- :_loop160_breakloop
+ goto _loop163_breakloop
+ :_loop163_breakloop
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2294,7 +2322,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2307,9 +2335,9 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
yt = LT(1)
match(YIELD)
- if ((tokenSet_12_.member(cast(int, LA(1)))) and (tokenSet_46_.member(cast(int, LA(2))))):
+ if ((tokenSet_14_.member(cast(int, LA(1)))) and (tokenSet_48_.member(cast(int, LA(2))))):
e=expression()
- elif ((tokenSet_15_.member(cast(int, LA(1)))) and (tokenSet_19_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_17_.member(cast(int, LA(1)))) and (tokenSet_21_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
@@ -2318,7 +2346,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2331,9 +2359,9 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
ret = LT(1)
match(RETURN)
- if ((tokenSet_12_.member(cast(int, LA(1)))) and (tokenSet_46_.member(cast(int, LA(2))))):
+ if ((tokenSet_14_.member(cast(int, LA(1)))) and (tokenSet_48_.member(cast(int, LA(2))))):
e=expression()
- elif ((tokenSet_15_.member(cast(int, LA(1)))) and (tokenSet_19_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_17_.member(cast(int, LA(1)))) and (tokenSet_21_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
@@ -2342,7 +2370,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2360,7 +2388,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2383,7 +2411,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2396,9 +2424,9 @@ partial class UnityScriptParser(antlr.LLkParser):
try: // for error handling
t = LT(1)
match(THROW)
- if ((tokenSet_12_.member(cast(int, LA(1)))) and (tokenSet_46_.member(cast(int, LA(2))))):
+ if ((tokenSet_14_.member(cast(int, LA(1)))) and (tokenSet_48_.member(cast(int, LA(2))))):
e=expression()
- elif ((tokenSet_15_.member(cast(int, LA(1)))) and (tokenSet_19_.member(cast(int, LA(2))))): // line 2102
+ elif ((tokenSet_17_.member(cast(int, LA(1)))) and (tokenSet_21_.member(cast(int, LA(2))))): // line 2102
pass // 947
else:
raise NoViableAltException(LT(1), getFilename())
@@ -2407,7 +2435,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_15_)
+ recover(ex,tokenSet_17_)
else:
raise
@@ -2429,6 +2457,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==CONTINUE)
or (_givenValue ==DO)
or (_givenValue ==ELSE)
+ or (_givenValue ==EACH)
or (_givenValue ==ENUM)
or (_givenValue ==FALSE)
or (_givenValue ==FINAL)
@@ -2475,7 +2504,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
or (_givenValue ==AT)
- or (_givenValue ==NOT)
+ or (_givenValue ==LOGICAL_NOT)
or (_givenValue ==RE_LITERAL)
or (_givenValue ==DOUBLE)
or (_givenValue ==INT)
@@ -2490,7 +2519,7 @@ partial class UnityScriptParser(antlr.LLkParser):
except ex as RecognitionException:
if (0 == inputState.guessing):
reportError(ex)
- recover(ex,tokenSet_47_)
+ recover(ex,tokenSet_49_)
else:
raise
return d
@@ -2590,6 +2619,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==CONTINUE)
or (_givenValue ==DO)
or (_givenValue ==ELSE)
+ or (_givenValue ==EACH)
or (_givenValue ==ENUM)
or (_givenValue ==FALSE)
or (_givenValue ==FINAL)
@@ -2635,7 +2665,7 @@ partial class UnityScriptParser(antlr.LLkParser):
or (_givenValue ==SUBTRACT)
or (_givenValue ==BITWISE_NOT)
or (_givenValue ==AT)
- or (_givenValue ==NOT)
+ or (_givenValue ==