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 0e5304b15d..20fe2a7535 100644 --- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.atg +++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/ExpressionFinder.atg @@ -517,6 +517,9 @@ Statement = | RaiseEventStatement | IfStatement | SelectStatement + | WhileStatement + | DoLoopStatement + | ForStatement | InvocationStatement . @@ -574,6 +577,45 @@ ComparisonOperator = "=" | "<>" | "<" | ">" | ">=" | "<=" . +WhileStatement = + "While" Expression StatementTerminatorAndBlock "End" "While" +. + +DoLoopStatement = + "Do" ( DoTopLoopStatement | DoBottomLoopStatement ) +. + +DoTopLoopStatement = + ( "While" | "Until" ) Expression + StatementTerminatorAndBlock + "Loop" +. + +DoBottomLoopStatement = + StatementTerminatorAndBlock + "Loop" [ ( "While" | "Until" ) Expression ] +. + +ForStatement = + "For" ( ForLoopStatement | ForEachLoopStatement ) +. + +ForLoopStatement = + ForLoopVariable "=" Expression /* "To" is binary operator */ [ "Step" Expression ] + StatementTerminatorAndBlock + "Next" [ Expression { "," Expression } ] +. + +ForEachLoopStatement = + "Each" ForLoopVariable "In" Expression + StatementTerminatorAndBlock + "Next" [ Expression { "," Expression } ] +. + +ForLoopVariable = + SimpleExpression [ "?" ] { ExpressionSuffix } +. + InvocationStatement = [ "Call" ] Expression . 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 a90aa5ed1c..f1c04a7bc8 100644 --- a/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Parser.cs +++ b/src/Libraries/NRefactory/Project/Src/Parser/VBNet/Experimental/Parser.cs @@ -52,7 +52,7 @@ int currentState = 0; if (t == null) { currentState = 1; break; } if (t.kind == 172) { stateStack.Push(1); - goto case 250; + goto case 288; } else { goto case 2; } @@ -61,7 +61,7 @@ int currentState = 0; if (t == null) { currentState = 2; break; } if (t.kind == 136) { stateStack.Push(2); - goto case 247; + goto case 285; } else { goto case 3; } @@ -70,7 +70,7 @@ int currentState = 0; if (t == null) { currentState = 3; break; } if (t.kind == 39) { stateStack.Push(3); - goto case 180; + goto case 218; } else { goto case 4; } @@ -89,7 +89,7 @@ int currentState = 0; case 5: { if (t == null) { currentState = 5; break; } if (t.kind == 159) { - goto case 243; + goto case 281; } else { if (set[1, t.kind]) { goto case 7; @@ -107,7 +107,7 @@ int currentState = 0; if (t == null) { currentState = 7; break; } if (t.kind == 39) { stateStack.Push(7); - goto case 180; + goto case 218; } else { goto case 8; } @@ -119,7 +119,7 @@ int currentState = 0; break; } else { if (t.kind == 83 || t.kind == 154) { - goto case 242; + goto case 280; } else { Error(t); goto case 9; @@ -129,7 +129,7 @@ int currentState = 0; case 9: { if (t == null) { currentState = 9; break; } if (set[3, t.kind]) { - goto case 242; + goto case 280; } else { stateStack.Push(10); goto case 15; @@ -190,7 +190,7 @@ int currentState = 0; if (t == null) { currentState = 18; break; } if (t.kind == 39) { stateStack.Push(18); - goto case 180; + goto case 218; } else { goto case 19; } @@ -203,23 +203,23 @@ int currentState = 0; } else { if (set[6, t.kind]) { stateStack.Push(20); - goto case 235; + goto case 273; } else { if (t.kind == 126 || t.kind == 208) { stateStack.Push(20); - goto case 223; + goto case 261; } else { if (t.kind == 100) { stateStack.Push(20); - goto case 212; + goto case 250; } else { if (t.kind == 118) { stateStack.Push(20); - goto case 202; + goto case 240; } else { if (t.kind == 97) { stateStack.Push(20); - goto case 190; + goto case 228; } else { if (t.kind == 171) { stateStack.Push(20); @@ -259,7 +259,7 @@ int currentState = 0; } case 24: { stateStack.Push(25); - goto case 185; + goto case 223; } case 25: { if (t == null) { currentState = 25; break; } @@ -270,7 +270,7 @@ int currentState = 0; case 26: { if (t == null) { currentState = 26; break; } if (t.kind == 62) { - currentState = 179; + currentState = 217; break; } else { goto case 27; @@ -321,27 +321,39 @@ int currentState = 0; case 34: { if (t == null) { currentState = 34; break; } if (t.kind == 87 || t.kind == 104 || t.kind == 202) { - goto case 162; + goto case 200; } else { if (t.kind == 209 || t.kind == 231) { - goto case 157; + goto case 195; } else { if (t.kind == 55 || t.kind == 191) { - goto case 154; + goto case 192; } else { if (t.kind == 187) { - goto case 151; + goto case 189; } else { if (t.kind == 134) { - goto case 133; + goto case 171; } else { if (t.kind == 195) { - goto case 120; + goto case 158; } else { - if (set[9, t.kind]) { - goto case 35; + if (t.kind == 229) { + goto case 153; } else { - goto case 6; + if (t.kind == 107) { + goto case 144; + } else { + if (t.kind == 123) { + goto case 120; + } else { + if (set[9, t.kind]) { + goto case 35; + } else { + goto case 6; + } + } + } } } } @@ -1005,167 +1017,139 @@ int currentState = 0; } case 120: { if (t == null) { currentState = 120; break; } - Expect(195, t); // "Select" + Expect(123, t); // "For" currentState = 121; break; } case 121: { if (t == null) { currentState = 121; break; } - if (t.kind == 73) { - currentState = 122; - break; + if (set[13, t.kind]) { + goto case 134; } else { - goto case 122; + if (t.kind == 109) { + goto case 122; + } else { + goto case 6; + } } } case 122: { - stateStack.Push(123); - goto case 37; + if (t == null) { currentState = 122; break; } + Expect(109, t); // "Each" + currentState = 123; + break; } case 123: { stateStack.Push(124); - goto case 15; + goto case 131; } case 124: { if (t == null) { currentState = 124; break; } - if (t.kind == 73) { - currentState = 126; - break; - } else { - Expect(112, t); // "End" - currentState = 125; - break; - } + Expect(137, t); // "In" + currentState = 125; + break; } case 125: { - if (t == null) { currentState = 125; break; } - Expect(195, t); // "Select" - currentState = stateStack.Pop(); - break; + stateStack.Push(126); + goto case 37; } case 126: { - if (t == null) { currentState = 126; break; } - if (t.kind == 110) { - currentState = 127; - break; - } else { - if (set[26, t.kind]) { - goto case 128; - } else { - Error(t); - goto case 127; - } - } + stateStack.Push(127); + goto case 31; } case 127: { - stateStack.Push(124); - goto case 31; + if (t == null) { currentState = 127; break; } + Expect(162, t); // "Next" + currentState = 128; + break; } case 128: { if (t == null) { currentState = 128; break; } - if (set[27, t.kind]) { - if (t.kind == 143) { - currentState = 130; - break; - } else { - goto case 130; - } + if (set[15, t.kind]) { + goto case 129; } else { - if (set[15, t.kind]) { - stateStack.Push(129); - goto case 37; - } else { - Error(t); - goto case 129; - } + currentState = stateStack.Pop(); + goto switchlbl; } } case 129: { - if (t == null) { currentState = 129; break; } + stateStack.Push(130); + goto case 37; + } + case 130: { + if (t == null) { currentState = 130; break; } if (t.kind == 23) { - currentState = 128; + currentState = 129; break; } else { - goto case 127; + currentState = stateStack.Pop(); + goto switchlbl; } } - case 130: { - stateStack.Push(131); - goto case 132; - } case 131: { - stateStack.Push(129); - goto case 50; + stateStack.Push(132); + goto case 99; } case 132: { if (t == null) { currentState = 132; break; } - if (set[28, t.kind]) { - goto case 16; + if (t.kind == 32) { + currentState = 133; + break; } else { - goto case 6; + goto case 133; } } case 133: { if (t == null) { currentState = 133; break; } - Expect(134, t); // "If" - currentState = 134; - break; + if (t.kind == 27 || t.kind == 28 || t.kind == 36) { + stateStack.Push(133); + goto case 91; + } else { + currentState = stateStack.Pop(); + goto switchlbl; + } } case 134: { stateStack.Push(135); - goto case 37; + goto case 131; } case 135: { if (t == null) { currentState = 135; break; } - if (t.kind == 212) { - currentState = 144; - break; - } else { - goto case 136; - } + Expect(21, t); // "=" + currentState = 136; + break; } case 136: { - if (t == null) { currentState = 136; break; } - if (t.kind == 1 || t.kind == 22) { - goto case 137; - } else { - goto case 6; - } + stateStack.Push(137); + goto case 37; } case 137: { - stateStack.Push(138); - goto case 31; - } - case 138: { - if (t == null) { currentState = 138; break; } - if (t.kind == 110 || t.kind == 111) { - if (t.kind == 110) { - currentState = 143; - break; - } else { - if (t.kind == 111) { - goto case 140; - } else { - Error(t); - goto case 137; - } - } - } else { - Expect(112, t); // "End" - currentState = 139; + if (t == null) { currentState = 137; break; } + if (t.kind == 203) { + currentState = 143; break; + } else { + goto case 138; } } + case 138: { + stateStack.Push(139); + goto case 31; + } case 139: { if (t == null) { currentState = 139; break; } - Expect(134, t); // "If" - currentState = stateStack.Pop(); + Expect(162, t); // "Next" + currentState = 140; break; } case 140: { if (t == null) { currentState = 140; break; } - currentState = 141; - break; + if (set[15, t.kind]) { + goto case 141; + } else { + currentState = stateStack.Pop(); + goto switchlbl; + } } case 141: { stateStack.Push(142); @@ -1173,302 +1157,571 @@ int currentState = 0; } case 142: { if (t == null) { currentState = 142; break; } - if (t.kind == 212) { - currentState = 137; + if (t.kind == 23) { + currentState = 141; break; } else { - goto case 137; + currentState = stateStack.Pop(); + goto switchlbl; } } case 143: { - if (t == null) { currentState = 143; break; } - if (t.kind == 134) { - goto case 140; - } else { - goto case 137; - } + stateStack.Push(138); + goto case 37; } case 144: { if (t == null) { currentState = 144; break; } - if (set[8, t.kind]) { - goto case 145; - } else { - goto case 136; - } + Expect(107, t); // "Do" + currentState = 145; + break; } case 145: { - stateStack.Push(146); - goto case 34; - } - case 146: { - if (t == null) { currentState = 146; break; } - if (t.kind == 22) { - currentState = 145; - break; + if (t == null) { currentState = 145; break; } + if (t.kind == 222 || t.kind == 229) { + goto case 149; } else { - if (t.kind == 110) { - goto case 148; + if (t.kind == 1 || t.kind == 22) { + goto case 146; } else { - goto case 147; + goto case 6; } } } + case 146: { + stateStack.Push(147); + goto case 31; + } case 147: { if (t == null) { currentState = 147; break; } - Expect(1, t); // EOL - currentState = stateStack.Pop(); + Expect(151, t); // "Loop" + currentState = 148; break; } case 148: { if (t == null) { currentState = 148; break; } - currentState = 149; - break; + if (t.kind == 222 || t.kind == 229) { + goto case 119; + } else { + currentState = stateStack.Pop(); + goto switchlbl; + } } case 149: { - stateStack.Push(150); - goto case 34; - } - case 150: { - if (t == null) { currentState = 150; break; } - if (t.kind == 22) { - goto case 148; + if (t == null) { currentState = 149; break; } + if (t.kind == 222 || t.kind == 229) { + currentState = 150; + break; } else { - goto case 147; + Error(t); + goto case 150; } } + case 150: { + stateStack.Push(151); + goto case 37; + } case 151: { - if (t == null) { currentState = 151; break; } - Expect(187, t); // "RaiseEvent" - currentState = 152; - break; + stateStack.Push(152); + goto case 31; } case 152: { - stateStack.Push(153); - goto case 16; + if (t == null) { currentState = 152; break; } + Expect(151, t); // "Loop" + currentState = stateStack.Pop(); + break; } case 153: { if (t == null) { currentState = 153; break; } - if (t.kind == 36) { - currentState = 76; - break; - } else { - currentState = stateStack.Pop(); - goto switchlbl; - } + Expect(229, t); // "While" + currentState = 154; + break; } case 154: { - if (t == null) { currentState = 154; break; } - if (t.kind == 55 || t.kind == 191) { - currentState = 155; - break; - } else { - Error(t); - goto case 155; - } + stateStack.Push(155); + goto case 37; } case 155: { stateStack.Push(156); - goto case 37; + goto case 31; } case 156: { if (t == null) { currentState = 156; break; } - Expect(23, t); // "," - currentState = 36; + Expect(112, t); // "End" + currentState = 157; break; } case 157: { if (t == null) { currentState = 157; break; } - if (t.kind == 209 || t.kind == 231) { - currentState = 158; - break; - } else { - Error(t); - goto case 158; - } + Expect(229, t); // "While" + currentState = stateStack.Pop(); + break; } case 158: { - stateStack.Push(159); - goto case 37; + if (t == null) { currentState = 158; break; } + Expect(195, t); // "Select" + currentState = 159; + break; } case 159: { - stateStack.Push(160); - goto case 31; + if (t == null) { currentState = 159; break; } + if (t.kind == 73) { + currentState = 160; + break; + } else { + goto case 160; + } } case 160: { - if (t == null) { currentState = 160; break; } - Expect(112, t); // "End" - currentState = 161; - break; + stateStack.Push(161); + goto case 37; } case 161: { - if (t == null) { currentState = 161; break; } - if (t.kind == 209 || t.kind == 231) { - goto case 16; - } else { - goto case 6; - } + stateStack.Push(162); + goto case 15; } case 162: { if (t == null) { currentState = 162; break; } - if (t.kind == 87 || t.kind == 104 || t.kind == 202) { - currentState = 163; + if (t.kind == 73) { + currentState = 164; break; } else { - Error(t); - goto case 163; + Expect(112, t); // "End" + currentState = 163; + break; } } case 163: { - stateStack.Push(164); - goto case 84; + if (t == null) { currentState = 163; break; } + Expect(195, t); // "Select" + currentState = stateStack.Pop(); + break; } case 164: { if (t == null) { currentState = 164; break; } - if (t.kind == 32) { + if (t.kind == 110) { currentState = 165; break; } else { - goto case 165; + if (set[26, t.kind]) { + goto case 166; + } else { + Error(t); + goto case 165; + } } } case 165: { - if (t == null) { currentState = 165; break; } - if (t.kind == 36) { - goto case 177; - } else { - goto case 166; - } + stateStack.Push(162); + goto case 31; } case 166: { if (t == null) { currentState = 166; break; } - if (t.kind == 23) { - currentState = 171; - break; - } else { - if (t.kind == 62) { + if (set[27, t.kind]) { + if (t.kind == 143) { currentState = 168; break; } else { + goto case 168; + } + } else { + if (set[15, t.kind]) { + stateStack.Push(167); + goto case 37; + } else { + Error(t); goto case 167; } } } case 167: { if (t == null) { currentState = 167; break; } - if (t.kind == 21) { - goto case 119; + if (t.kind == 23) { + currentState = 166; + break; } else { - currentState = stateStack.Pop(); - goto switchlbl; + goto case 165; } } case 168: { - if (t == null) { currentState = 168; break; } - if (t.kind == 161) { - goto case 170; - } else { - goto case 169; - } + stateStack.Push(169); + goto case 170; } case 169: { stateStack.Push(167); - goto case 69; + goto case 50; } case 170: { if (t == null) { currentState = 170; break; } - currentState = 169; - break; + if (set[28, t.kind]) { + goto case 16; + } else { + goto case 6; + } } case 171: { - stateStack.Push(172); - goto case 84; + if (t == null) { currentState = 171; break; } + Expect(134, t); // "If" + currentState = 172; + break; } case 172: { - if (t == null) { currentState = 172; break; } - if (t.kind == 32) { - currentState = 173; - break; - } else { - goto case 173; - } + stateStack.Push(173); + goto case 37; } case 173: { if (t == null) { currentState = 173; break; } - if (t.kind == 36) { - goto case 174; + if (t.kind == 212) { + currentState = 182; + break; } else { - goto case 166; + goto case 174; } } case 174: { if (t == null) { currentState = 174; break; } - currentState = 175; - break; - } - case 175: { - if (t == null) { currentState = 175; break; } - if (t.kind == 23) { - goto case 174; + if (t.kind == 1 || t.kind == 22) { + goto case 175; } else { - goto case 176; + goto case 6; } } + case 175: { + stateStack.Push(176); + goto case 31; + } case 176: { if (t == null) { currentState = 176; break; } - Expect(37, t); // ")" - currentState = 166; - break; + if (t.kind == 110 || t.kind == 111) { + if (t.kind == 110) { + currentState = 181; + break; + } else { + if (t.kind == 111) { + goto case 178; + } else { + Error(t); + goto case 175; + } + } + } else { + Expect(112, t); // "End" + currentState = 177; + break; + } } case 177: { if (t == null) { currentState = 177; break; } - currentState = 178; + Expect(134, t); // "If" + currentState = stateStack.Pop(); break; } case 178: { if (t == null) { currentState = 178; break; } + currentState = 179; + break; + } + case 179: { + stateStack.Push(180); + goto case 37; + } + case 180: { + if (t == null) { currentState = 180; break; } + if (t.kind == 212) { + currentState = 175; + break; + } else { + goto case 175; + } + } + case 181: { + if (t == null) { currentState = 181; break; } + if (t.kind == 134) { + goto case 178; + } else { + goto case 175; + } + } + case 182: { + if (t == null) { currentState = 182; break; } + if (set[8, t.kind]) { + goto case 183; + } else { + goto case 174; + } + } + case 183: { + stateStack.Push(184); + goto case 34; + } + case 184: { + if (t == null) { currentState = 184; break; } + if (t.kind == 22) { + currentState = 183; + break; + } else { + if (t.kind == 110) { + goto case 186; + } else { + goto case 185; + } + } + } + case 185: { + if (t == null) { currentState = 185; break; } + Expect(1, t); // EOL + currentState = stateStack.Pop(); + break; + } + case 186: { + if (t == null) { currentState = 186; break; } + currentState = 187; + break; + } + case 187: { + stateStack.Push(188); + goto case 34; + } + case 188: { + if (t == null) { currentState = 188; break; } + if (t.kind == 22) { + goto case 186; + } else { + goto case 185; + } + } + case 189: { + if (t == null) { currentState = 189; break; } + Expect(187, t); // "RaiseEvent" + currentState = 190; + break; + } + case 190: { + stateStack.Push(191); + goto case 16; + } + case 191: { + if (t == null) { currentState = 191; break; } + if (t.kind == 36) { + currentState = 76; + break; + } else { + currentState = stateStack.Pop(); + goto switchlbl; + } + } + case 192: { + if (t == null) { currentState = 192; break; } + if (t.kind == 55 || t.kind == 191) { + currentState = 193; + break; + } else { + Error(t); + goto case 193; + } + } + case 193: { + stateStack.Push(194); + goto case 37; + } + case 194: { + if (t == null) { currentState = 194; break; } + Expect(23, t); // "," + currentState = 36; + break; + } + case 195: { + if (t == null) { currentState = 195; break; } + if (t.kind == 209 || t.kind == 231) { + currentState = 196; + break; + } else { + Error(t); + goto case 196; + } + } + case 196: { + stateStack.Push(197); + goto case 37; + } + case 197: { + stateStack.Push(198); + goto case 31; + } + case 198: { + if (t == null) { currentState = 198; break; } + Expect(112, t); // "End" + currentState = 199; + break; + } + case 199: { + if (t == null) { currentState = 199; break; } + if (t.kind == 209 || t.kind == 231) { + goto case 16; + } else { + goto case 6; + } + } + case 200: { + if (t == null) { currentState = 200; break; } + if (t.kind == 87 || t.kind == 104 || t.kind == 202) { + currentState = 201; + break; + } else { + Error(t); + goto case 201; + } + } + case 201: { + stateStack.Push(202); + goto case 84; + } + case 202: { + if (t == null) { currentState = 202; break; } + if (t.kind == 32) { + currentState = 203; + break; + } else { + goto case 203; + } + } + case 203: { + if (t == null) { currentState = 203; break; } + if (t.kind == 36) { + goto case 215; + } else { + goto case 204; + } + } + case 204: { + if (t == null) { currentState = 204; break; } if (t.kind == 23) { - goto case 177; + currentState = 209; + break; } else { - goto case 176; + if (t.kind == 62) { + currentState = 206; + break; + } else { + goto case 205; + } } } - case 179: { - if (t == null) { currentState = 179; break; } + case 205: { + if (t == null) { currentState = 205; break; } + if (t.kind == 21) { + goto case 119; + } else { + currentState = stateStack.Pop(); + goto switchlbl; + } + } + case 206: { + if (t == null) { currentState = 206; break; } + if (t.kind == 161) { + goto case 208; + } else { + goto case 207; + } + } + case 207: { + stateStack.Push(205); + goto case 69; + } + case 208: { + if (t == null) { currentState = 208; break; } + currentState = 207; + break; + } + case 209: { + stateStack.Push(210); + goto case 84; + } + case 210: { + if (t == null) { currentState = 210; break; } + if (t.kind == 32) { + currentState = 211; + break; + } else { + goto case 211; + } + } + case 211: { + if (t == null) { currentState = 211; break; } + if (t.kind == 36) { + goto case 212; + } else { + goto case 204; + } + } + case 212: { + if (t == null) { currentState = 212; break; } + currentState = 213; + break; + } + case 213: { + if (t == null) { currentState = 213; break; } + if (t.kind == 23) { + goto case 212; + } else { + goto case 214; + } + } + case 214: { + if (t == null) { currentState = 214; break; } + Expect(37, t); // ")" + currentState = 204; + break; + } + case 215: { + if (t == null) { currentState = 215; break; } + currentState = 216; + break; + } + case 216: { + if (t == null) { currentState = 216; break; } + if (t.kind == 23) { + goto case 215; + } else { + goto case 214; + } + } + case 217: { + if (t == null) { currentState = 217; break; } if (t.kind == 39) { - stateStack.Push(179); - goto case 180; + stateStack.Push(217); + goto case 218; } else { stateStack.Push(27); goto case 69; } } - case 180: { - if (t == null) { currentState = 180; break; } + case 218: { + if (t == null) { currentState = 218; break; } Expect(39, t); // "<" - currentState = 181; + currentState = 219; break; } - case 181: { + case 219: { PushContext(Context.Attribute, t); - goto case 182; + goto case 220; } - case 182: { - if (t == null) { currentState = 182; break; } + case 220: { + if (t == null) { currentState = 220; break; } if (set[29, t.kind]) { - currentState = 182; + currentState = 220; break; } else { Expect(38, t); // ">" - currentState = 183; + currentState = 221; break; } } - case 183: { + case 221: { PopContext(); - goto case 184; + goto case 222; } - case 184: { - if (t == null) { currentState = 184; break; } + case 222: { + if (t == null) { currentState = 222; break; } if (t.kind == 1) { goto case 16; } else { @@ -1476,334 +1729,334 @@ int currentState = 0; goto switchlbl; } } - case 185: { - stateStack.Push(186); - goto case 187; + case 223: { + stateStack.Push(224); + goto case 225; } - case 186: { - if (t == null) { currentState = 186; break; } + case 224: { + if (t == null) { currentState = 224; break; } if (t.kind == 23) { - currentState = 185; + currentState = 223; break; } else { currentState = stateStack.Pop(); goto switchlbl; } } - case 187: { - if (t == null) { currentState = 187; break; } + case 225: { + if (t == null) { currentState = 225; break; } if (t.kind == 39) { - stateStack.Push(187); - goto case 180; + stateStack.Push(225); + goto case 218; } else { - goto case 188; + goto case 226; } } - case 188: { - if (t == null) { currentState = 188; break; } + case 226: { + if (t == null) { currentState = 226; break; } if (set[30, t.kind]) { - currentState = 188; + currentState = 226; break; } else { - stateStack.Push(189); + stateStack.Push(227); goto case 84; } } - case 189: { - if (t == null) { currentState = 189; break; } + case 227: { + if (t == null) { currentState = 227; break; } if (t.kind == 62) { - goto case 170; + goto case 208; } else { - goto case 167; + goto case 205; } } - case 190: { - if (t == null) { currentState = 190; break; } + case 228: { + if (t == null) { currentState = 228; break; } Expect(97, t); // "Custom" - currentState = 191; + currentState = 229; break; } - case 191: { - stateStack.Push(192); - goto case 202; + case 229: { + stateStack.Push(230); + goto case 240; } - case 192: { - if (t == null) { currentState = 192; break; } + case 230: { + if (t == null) { currentState = 230; break; } if (set[31, t.kind]) { - goto case 194; + goto case 232; } else { Expect(112, t); // "End" - currentState = 193; + currentState = 231; break; } } - case 193: { - if (t == null) { currentState = 193; break; } + case 231: { + if (t == null) { currentState = 231; break; } Expect(118, t); // "Event" currentState = 30; break; } - case 194: { - if (t == null) { currentState = 194; break; } + case 232: { + if (t == null) { currentState = 232; break; } if (t.kind == 39) { - stateStack.Push(194); - goto case 180; + stateStack.Push(232); + goto case 218; } else { if (t.kind == 55 || t.kind == 187 || t.kind == 191) { - currentState = 195; + currentState = 233; break; } else { Error(t); - goto case 195; + goto case 233; } } } - case 195: { - if (t == null) { currentState = 195; break; } + case 233: { + if (t == null) { currentState = 233; break; } Expect(36, t); // "(" - currentState = 196; + currentState = 234; break; } - case 196: { - stateStack.Push(197); - goto case 185; + case 234: { + stateStack.Push(235); + goto case 223; } - case 197: { - if (t == null) { currentState = 197; break; } + case 235: { + if (t == null) { currentState = 235; break; } Expect(37, t); // ")" - currentState = 198; + currentState = 236; break; } - case 198: { - stateStack.Push(199); + case 236: { + stateStack.Push(237); goto case 31; } - case 199: { - if (t == null) { currentState = 199; break; } + case 237: { + if (t == null) { currentState = 237; break; } Expect(112, t); // "End" - currentState = 200; + currentState = 238; break; } - case 200: { - if (t == null) { currentState = 200; break; } + case 238: { + if (t == null) { currentState = 238; break; } if (t.kind == 55 || t.kind == 187 || t.kind == 191) { - currentState = 201; + currentState = 239; break; } else { Error(t); - goto case 201; + goto case 239; } } - case 201: { - stateStack.Push(192); + case 239: { + stateStack.Push(230); goto case 15; } - case 202: { - if (t == null) { currentState = 202; break; } + case 240: { + if (t == null) { currentState = 240; break; } Expect(118, t); // "Event" - currentState = 203; + currentState = 241; break; } - case 203: { - stateStack.Push(204); + case 241: { + stateStack.Push(242); goto case 84; } - case 204: { - if (t == null) { currentState = 204; break; } + case 242: { + if (t == null) { currentState = 242; break; } if (t.kind == 62) { - currentState = 211; + currentState = 249; break; } else { if (set[32, t.kind]) { if (t.kind == 36) { - currentState = 209; + currentState = 247; break; } else { - goto case 205; + goto case 243; } } else { Error(t); - goto case 205; + goto case 243; } } } - case 205: { - if (t == null) { currentState = 205; break; } + case 243: { + if (t == null) { currentState = 243; break; } if (t.kind == 135) { - goto case 206; + goto case 244; } else { goto case 30; } } - case 206: { - if (t == null) { currentState = 206; break; } - currentState = 207; + case 244: { + if (t == null) { currentState = 244; break; } + currentState = 245; break; } - case 207: { - stateStack.Push(208); + case 245: { + stateStack.Push(246); goto case 69; } - case 208: { - if (t == null) { currentState = 208; break; } + case 246: { + if (t == null) { currentState = 246; break; } if (t.kind == 23) { - goto case 206; + goto case 244; } else { goto case 30; } } - case 209: { - if (t == null) { currentState = 209; break; } + case 247: { + if (t == null) { currentState = 247; break; } if (set[33, t.kind]) { - stateStack.Push(210); - goto case 185; + stateStack.Push(248); + goto case 223; } else { - goto case 210; + goto case 248; } } - case 210: { - if (t == null) { currentState = 210; break; } + case 248: { + if (t == null) { currentState = 248; break; } Expect(37, t); // ")" - currentState = 205; + currentState = 243; break; } - case 211: { - stateStack.Push(205); + case 249: { + stateStack.Push(243); goto case 69; } - case 212: { - if (t == null) { currentState = 212; break; } + case 250: { + if (t == null) { currentState = 250; break; } Expect(100, t); // "Declare" - currentState = 213; + currentState = 251; break; } - case 213: { - if (t == null) { currentState = 213; break; } + case 251: { + if (t == null) { currentState = 251; break; } if (t.kind == 61 || t.kind == 65 || t.kind == 221) { - currentState = 214; + currentState = 252; break; } else { - goto case 214; + goto case 252; } } - case 214: { - if (t == null) { currentState = 214; break; } + case 252: { + if (t == null) { currentState = 252; break; } if (t.kind == 126 || t.kind == 208) { - currentState = 215; + currentState = 253; break; } else { Error(t); - goto case 215; + goto case 253; } } - case 215: { - stateStack.Push(216); + case 253: { + stateStack.Push(254); goto case 84; } - case 216: { - if (t == null) { currentState = 216; break; } + case 254: { + if (t == null) { currentState = 254; break; } Expect(148, t); // "Lib" - currentState = 217; + currentState = 255; break; } - case 217: { - if (t == null) { currentState = 217; break; } + case 255: { + if (t == null) { currentState = 255; break; } Expect(3, t); // LiteralString - currentState = 218; + currentState = 256; break; } - case 218: { - if (t == null) { currentState = 218; break; } + case 256: { + if (t == null) { currentState = 256; break; } if (t.kind == 58) { - currentState = 222; + currentState = 260; break; } else { - goto case 219; + goto case 257; } } - case 219: { - if (t == null) { currentState = 219; break; } + case 257: { + if (t == null) { currentState = 257; break; } if (t.kind == 36) { - currentState = 220; + currentState = 258; break; } else { goto case 30; } } - case 220: { - if (t == null) { currentState = 220; break; } + case 258: { + if (t == null) { currentState = 258; break; } if (set[33, t.kind]) { - stateStack.Push(221); - goto case 185; + stateStack.Push(259); + goto case 223; } else { - goto case 221; + goto case 259; } } - case 221: { - if (t == null) { currentState = 221; break; } + case 259: { + if (t == null) { currentState = 259; break; } Expect(37, t); // ")" currentState = 30; break; } - case 222: { - if (t == null) { currentState = 222; break; } + case 260: { + if (t == null) { currentState = 260; break; } Expect(3, t); // LiteralString - currentState = 219; + currentState = 257; break; } - case 223: { - if (t == null) { currentState = 223; break; } + case 261: { + if (t == null) { currentState = 261; break; } if (t.kind == 126 || t.kind == 208) { - currentState = 224; + currentState = 262; break; } else { Error(t); - goto case 224; + goto case 262; } } - case 224: { + case 262: { PushContext(Context.IdentifierExpected, t); - goto case 225; + goto case 263; } - case 225: { - if (t == null) { currentState = 225; break; } - currentState = 226; + case 263: { + if (t == null) { currentState = 263; break; } + currentState = 264; break; } - case 226: { + case 264: { PopContext(); - goto case 227; + goto case 265; } - case 227: { - if (t == null) { currentState = 227; break; } + case 265: { + if (t == null) { currentState = 265; break; } if (t.kind == 36) { - currentState = 233; + currentState = 271; break; } else { - goto case 228; + goto case 266; } } - case 228: { - if (t == null) { currentState = 228; break; } + case 266: { + if (t == null) { currentState = 266; break; } if (t.kind == 62) { - currentState = 232; + currentState = 270; break; } else { - goto case 229; + goto case 267; } } - case 229: { - stateStack.Push(230); + case 267: { + stateStack.Push(268); goto case 31; } - case 230: { - if (t == null) { currentState = 230; break; } + case 268: { + if (t == null) { currentState = 268; break; } Expect(112, t); // "End" - currentState = 231; + currentState = 269; break; } - case 231: { - if (t == null) { currentState = 231; break; } + case 269: { + if (t == null) { currentState = 269; break; } if (t.kind == 126 || t.kind == 208) { currentState = 30; break; @@ -1812,139 +2065,139 @@ int currentState = 0; goto case 30; } } - case 232: { - stateStack.Push(229); + case 270: { + stateStack.Push(267); goto case 69; } - case 233: { - if (t == null) { currentState = 233; break; } + case 271: { + if (t == null) { currentState = 271; break; } if (set[33, t.kind]) { - stateStack.Push(234); - goto case 185; + stateStack.Push(272); + goto case 223; } else { - goto case 234; + goto case 272; } } - case 234: { - if (t == null) { currentState = 234; break; } + case 272: { + if (t == null) { currentState = 272; break; } Expect(37, t); // ")" - currentState = 228; + currentState = 266; break; } - case 235: { - if (t == null) { currentState = 235; break; } + case 273: { + if (t == null) { currentState = 273; break; } if (t.kind == 87) { - currentState = 236; + currentState = 274; break; } else { - goto case 236; + goto case 274; } } - case 236: { - stateStack.Push(237); - goto case 241; + case 274: { + stateStack.Push(275); + goto case 279; } - case 237: { - if (t == null) { currentState = 237; break; } + case 275: { + if (t == null) { currentState = 275; break; } if (t.kind == 62) { - currentState = 240; + currentState = 278; break; } else { - goto case 238; + goto case 276; } } - case 238: { - if (t == null) { currentState = 238; break; } + case 276: { + if (t == null) { currentState = 276; break; } if (t.kind == 21) { - currentState = 239; + currentState = 277; break; } else { goto case 30; } } - case 239: { + case 277: { stateStack.Push(30); goto case 37; } - case 240: { - stateStack.Push(238); + case 278: { + stateStack.Push(276); goto case 69; } - case 241: { - if (t == null) { currentState = 241; break; } + case 279: { + if (t == null) { currentState = 279; break; } if (set[34, t.kind]) { goto case 16; } else { goto case 6; } } - case 242: { - if (t == null) { currentState = 242; break; } + case 280: { + if (t == null) { currentState = 280; break; } currentState = 9; break; } - case 243: { - if (t == null) { currentState = 243; break; } + case 281: { + if (t == null) { currentState = 281; break; } Expect(159, t); // "Namespace" - currentState = 244; + currentState = 282; break; } - case 244: { - if (t == null) { currentState = 244; break; } + case 282: { + if (t == null) { currentState = 282; break; } if (set[3, t.kind]) { - currentState = 244; + currentState = 282; break; } else { - stateStack.Push(245); + stateStack.Push(283); goto case 15; } } - case 245: { - if (t == null) { currentState = 245; break; } + case 283: { + if (t == null) { currentState = 283; break; } if (set[35, t.kind]) { - stateStack.Push(245); + stateStack.Push(283); goto case 5; } else { Expect(112, t); // "End" - currentState = 246; + currentState = 284; break; } } - case 246: { - if (t == null) { currentState = 246; break; } + case 284: { + if (t == null) { currentState = 284; break; } Expect(159, t); // "Namespace" currentState = 30; break; } - case 247: { - if (t == null) { currentState = 247; break; } + case 285: { + if (t == null) { currentState = 285; break; } Expect(136, t); // "Imports" - currentState = 248; + currentState = 286; break; } - case 248: { + case 286: { nextTokenIsPotentialStartOfXmlMode = true; - goto case 249; + goto case 287; } - case 249: { - if (t == null) { currentState = 249; break; } + case 287: { + if (t == null) { currentState = 287; break; } if (set[3, t.kind]) { - currentState = 249; + currentState = 287; break; } else { goto case 30; } } - case 250: { - if (t == null) { currentState = 250; break; } + case 288: { + if (t == null) { currentState = 288; break; } Expect(172, t); // "Option" - currentState = 251; + currentState = 289; break; } - case 251: { - if (t == null) { currentState = 251; break; } + case 289: { + if (t == null) { currentState = 289; break; } if (set[3, t.kind]) { - currentState = 251; + currentState = 289; break; } else { goto case 30; @@ -1968,8 +2221,8 @@ int currentState = 0; {x,x,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,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,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, T,x,x,T, T,x,T,x, x,x,x,x, x,x,x,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,x,T,x, x,T,T,x, x,x,x,x, x,x,x,x, T,x,x,x, T,x,x,x, x,x,T,x, x,T,x,T, 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,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, 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, T,x,x,x, T,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,T,x, T,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,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,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,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,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,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, T,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, T,x,x,T, T,T,T,T, T,x,T,x, T,T,T,T, x,T,T,T, T,T,T,T, T,T,x,x, x,x,x,T, T,T,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,x,x,x, T,x,T,x, x,x,T,x, x,x,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,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,T, x,x,x,x, x,T,T,x, x,x,x,x, x,T,T,T, x,x,x,T, x,T,T,x, x,T,T,x, x,x,x,x, T,x,x,T, x,x,x,T, x,x}, - {x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,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, T,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, T,x,x,T, T,T,T,T, T,x,T,x, T,T,T,T, x,T,T,T, T,T,T,T, T,T,x,x, x,x,x,T, T,T,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,x,x,x, T,x,T,x, x,x,T,x, x,x,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,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,T, x,x,x,x, x,T,T,x, x,x,x,x, x,T,T,T, x,x,x,T, x,T,T,x, x,T,T,x, x,x,x,x, T,x,x,T, x,x,x,T, x,x}, + {x,T,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,T,x,x, x,x,T,x, x,x,x,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, T,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, T,x,x,T, T,T,T,T, T,x,T,x, T,T,T,T, x,T,T,T, T,T,T,T, T,T,x,x, x,x,x,T, T,T,T,T, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,T, x,T,x,x, T,x,x,x, T,x,T,x, x,x,T,x, x,x,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,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,T, x,x,x,x, x,T,T,x, x,x,x,x, x,T,T,T, x,x,x,T, x,T,T,x, x,T,T,x, x,x,x,x, T,T,x,T, x,x,x,T, x,x}, + {x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,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, T,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, T,x,x,T, T,T,T,T, T,x,T,x, T,T,T,T, x,T,T,T, T,T,T,T, T,T,x,x, x,x,x,T, T,T,T,T, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,T, x,T,x,x, T,x,x,x, T,x,T,x, x,x,T,x, x,x,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, T,x,x,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,T, x,x,x,x, x,T,T,x, x,x,x,x, x,T,T,T, x,x,x,T, x,T,T,x, x,T,T,x, x,x,x,x, T,T,x,T, x,x,x,T, x,x}, {x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,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, T,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, T,x,x,T, T,T,T,T, T,x,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,x,x,x, T,x,T,x, x,x,T,x, x,x,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, T,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,T, x,T,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,x,x,T, x,x}, {x,x,T,T, T,T,T,T, T,T,T,x, x,x,x,x, x,T,x,x, x,x,x,x, x,x,x,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, T,T,x,x, x,T,x,T, T,T,T,x, x,T,x,x, x,x,x,T, T,T,T,T, T,x,T,x, T,T,T,x, x,T,T,T, T,T,T,T, T,T,x,x, x,x,x,T, x,T,T,x, x,x,x,x, x,x,x,T, x,x,x,x, T,T,x,x, x,T,x,x, T,x,x,x, T,x,x,x, x,x,T,x, x,x,T,x, x,T,T,x, x,x,x,x, T,x,x,x, x,T,T,x, x,T,x,T, T,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,T, x,T,T,x, x,T,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, x,x,x,x, x,T,x,x, T,T,T,x, x,T,T,T, x,T,x,x, x,x,T,T, T,T,T,T, T,T,T,T, T,T,T,T, T,T,T,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,T, T,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,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,T,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,x,x, x,x,T,x, x,x},