private int JjMoveNfa_1(int startState, int curPos)
{
int startsAt = 0;
jjnewStateCnt = 38;
int i = 1;
jjstateSet[0] = startState;
int kind = 0x7fffffff;
for (; ; )
{
if (++jjround == 0x7fffffff)
ReInitRounds();
if (curChar < 64)
{
ulong l = (ulong)(1L << (int)curChar);
do
{
switch (jjstateSet[--i])
{
case 0:
if ((0x7bffe8faffffd9ffL & l) != 0L)
{
if (kind > 22)
kind = 22;
JjCheckNAddStates(0, 4);
}
else if ((0x100002600L & l) != 0L)
{
if (kind > 7)
kind = 7;
}
else if (curChar == 34)
JjCheckNAddStates(5, 7);
if ((0x3fc000000000000L & l) != 0L)
JjCheckNAddStates(8, 11);
else if (curChar == 49)
JjCheckNAddTwoStates(20, 21);
break;
case 19:
if ((0x3fc000000000000L & l) != 0L)
JjCheckNAddStates(8, 11);
break;
case 20:
if ((0x3ff000000000000L & l) != 0L)
JjCheckNAdd(17);
break;
case 21:
if ((0x3ff000000000000L & l) != 0L)
JjCheckNAdd(18);
break;
case 22:
if (curChar == 49)
JjCheckNAddTwoStates(20, 21);
break;
case 23:
if (curChar == 34)
JjCheckNAddStates(5, 7);
break;
case 24:
if ((0xfffffffbffffffffL & l) != (ulong)0L)
JjCheckNAddTwoStates(24, 25);
break;
case 25:
if (curChar == 34)
jjstateSet[jjnewStateCnt++] = 26;
break;
case 26:
if (curChar == 42 && kind > 18)
kind = 18;
break;
case 27:
if ((0xfffffffbffffffffL & l) != (ulong)0L)
JjCheckNAddStates(12, 14);
break;
case 29:
if (curChar == 34)
JjCheckNAddStates(12, 14);
break;
case 30:
if (curChar == 34 && kind > 19)
kind = 19;
break;
case 31:
if ((0x7bffe8faffffd9ffL & l) == 0L)
break;
if (kind > 22)
kind = 22;
JjCheckNAddStates(0, 4);
break;
case 32:
if ((0x7bffe8faffffd9ffL & l) != 0L)
JjCheckNAddTwoStates(32, 33);
break;
case 33:
if (curChar == 42 && kind > 20)
kind = 20;
break;
case 34:
if ((0x7bffe8faffffd9ffL & l) != 0L)
JjCheckNAddTwoStates(34, 35);
break;
case 35:
if ((0x8000040000000000L & l) == (ulong)0L)
break;
if (kind > 21)
kind = 21;
JjCheckNAddTwoStates(35, 36);
break;
case 36:
if ((0xfbffecfaffffd9ffL & l) == (ulong)0L)
break;
if (kind > 21)
kind = 21;
JjCheckNAdd(36);
break;
case 37:
if ((0x7bffe8faffffd9ffL & l) == 0L)
break;
if (kind > 22)
kind = 22;
JjCheckNAdd(37);
break;
default: break;
}
} while (i != startsAt);
}
else if (curChar < 128)
{
// NOTE: See the note in the Classic.QueryParserTokenManager.cs file.
// I am working under the assumption 63 is the correct value, since it
// made the tests pass there.
ulong l = (ulong)(1L << (curChar & 63));
//long l = 1L << (curChar & 077);
do
{
switch (jjstateSet[--i])
{
case 0:
if ((0xffffffffbfffffffL & l) != (ulong)0L)
{
if (kind > 22)
kind = 22;
JjCheckNAddStates(0, 4);
}
if ((0x400000004000L & l) != 0L)
{
if (kind > 12)
kind = 12;
}
else if ((0x80000000800000L & l) != 0L)
{
if (kind > 11)
kind = 11;
}
else if (curChar == 97)
jjstateSet[jjnewStateCnt++] = 9;
else if (curChar == 65)
jjstateSet[jjnewStateCnt++] = 6;
else if (curChar == 111)
jjstateSet[jjnewStateCnt++] = 3;
else if (curChar == 79)
jjstateSet[jjnewStateCnt++] = 1;
if (curChar == 110)
jjstateSet[jjnewStateCnt++] = 15;
else if (curChar == 78)
jjstateSet[jjnewStateCnt++] = 12;
break;
case 1:
if (curChar == 82 && kind > 8)
kind = 8;
break;
case 2:
if (curChar == 79)
jjstateSet[jjnewStateCnt++] = 1;
break;
case 3:
if (curChar == 114 && kind > 8)
kind = 8;
break;
case 4:
if (curChar == 111)
jjstateSet[jjnewStateCnt++] = 3;
break;
case 5:
if (curChar == 68 && kind > 9)
kind = 9;
break;
case 6:
if (curChar == 78)
jjstateSet[jjnewStateCnt++] = 5;
break;
case 7:
if (curChar == 65)
jjstateSet[jjnewStateCnt++] = 6;
break;
case 8:
if (curChar == 100 && kind > 9)
kind = 9;
break;
case 9:
if (curChar == 110)
jjstateSet[jjnewStateCnt++] = 8;
break;
case 10:
if (curChar == 97)
jjstateSet[jjnewStateCnt++] = 9;
break;
case 11:
if (curChar == 84 && kind > 10)
kind = 10;
break;
case 12:
if (curChar == 79)
jjstateSet[jjnewStateCnt++] = 11;
break;
case 13:
if (curChar == 78)
jjstateSet[jjnewStateCnt++] = 12;
break;
case 14:
if (curChar == 116 && kind > 10)
kind = 10;
break;
case 15:
if (curChar == 111)
jjstateSet[jjnewStateCnt++] = 14;
break;
case 16:
if (curChar == 110)
jjstateSet[jjnewStateCnt++] = 15;
break;
case 17:
if ((0x80000000800000L & l) != 0L && kind > 11)
kind = 11;
break;
case 18:
if ((0x400000004000L & l) != 0L && kind > 12)
kind = 12;
break;
case 24:
JjAddStates(15, 16);
break;
case 27:
if ((0xffffffffefffffffL & l) != (ulong)0L)
JjCheckNAddStates(12, 14);
break;
case 28:
if (curChar == 92)
jjstateSet[jjnewStateCnt++] = 29;
break;
case 29:
if (curChar == 92)
JjCheckNAddStates(12, 14);
break;
case 31:
if ((0xffffffffbfffffffL & l) == (ulong)0L)
break;
if (kind > 22)
kind = 22;
JjCheckNAddStates(0, 4);
break;
case 32:
if ((0xffffffffbfffffffL & l) != (ulong)0L)
JjCheckNAddTwoStates(32, 33);
break;
case 34:
if ((0xffffffffbfffffffL & l) != (ulong)0L)
JjCheckNAddTwoStates(34, 35);
break;
case 36:
if ((0xffffffffbfffffffL & l) == (ulong)0L)
break;
if (kind > 21)
kind = 21;
jjstateSet[jjnewStateCnt++] = 36;
break;
case 37:
if ((0xffffffffbfffffffL & l) == (ulong)0L)
break;
if (kind > 22)
kind = 22;
JjCheckNAdd(37);
break;
default: break;
}
} while (i != startsAt);
}
else
{
int hiByte = (int)(curChar >> 8);
int i1 = hiByte >> 6;
//long l1 = 1L << (hiByte & 077);
ulong l1 = (ulong)(1L << (hiByte & 63));
int i2 = (curChar & 0xff) >> 6;
//long l2 = 1L << (curChar & 077);
ulong l2 = (ulong)(1L << (curChar & 63));
do
{
switch (jjstateSet[--i])
{
case 0:
if (!JjCanMove_0(hiByte, i1, i2, l1, l2))
break;
if (kind > 22)
kind = 22;
JjCheckNAddStates(0, 4);
break;
case 24:
if (JjCanMove_0(hiByte, i1, i2, l1, l2))
JjAddStates(15, 16);
break;
case 27:
if (JjCanMove_0(hiByte, i1, i2, l1, l2))
JjAddStates(12, 14);
break;
case 32:
if (JjCanMove_0(hiByte, i1, i2, l1, l2))
JjCheckNAddTwoStates(32, 33);
break;
case 34:
if (JjCanMove_0(hiByte, i1, i2, l1, l2))
JjCheckNAddTwoStates(34, 35);
break;
case 36:
if (!JjCanMove_0(hiByte, i1, i2, l1, l2))
break;
if (kind > 21)
kind = 21;
jjstateSet[jjnewStateCnt++] = 36;
break;
case 37:
if (!JjCanMove_0(hiByte, i1, i2, l1, l2))
break;
if (kind > 22)
kind = 22;
JjCheckNAdd(37);
break;
default: break;
}
} while (i != startsAt);
}
if (kind != 0x7fffffff)
{
jjmatchedKind = kind;
jjmatchedPos = curPos;
kind = 0x7fffffff;
}
++curPos;
if ((i = jjnewStateCnt) == (startsAt = 38 - (jjnewStateCnt = startsAt)))
return curPos;
try { curChar = input_stream.ReadChar(); }
catch (System.IO.IOException /*e*/) { return curPos; }
}
}