in src/Lucene.Net.QueryParser/Classic/QueryParserTokenManager.cs [904:1068]
private int JjMoveNfa_1(int startState, int curPos)
{
int startsAt = 0;
jjnewStateCnt = 7;
int i = 1;
jjstateSet[0] = startState;
int kind = 0x7fffffff;
for (; ; )
{
if (++jjround == 0x7fffffff)
ReInitRounds();
if (m_curChar < 64)
{
ulong l = (ulong) (1L << (int) m_curChar);
do
{
switch (jjstateSet[--i])
{
case 0:
if ((0xfffffffeffffffffL & l) != (ulong)0L)
{
if (kind > 32)
kind = 32;
JjCheckNAdd(6);
}
if ((0x100002600L & l) != 0L)
{
if (kind > 7)
kind = 7;
}
else if (m_curChar == 34)
JjCheckNAddTwoStates(2, 4);
break;
case 1:
if (m_curChar == 34)
JjCheckNAddTwoStates(2, 4);
break;
case 2:
if ((0xfffffffbffffffffL & l) != (ulong)0L)
JjCheckNAddStates(33, 35);
break;
case 3:
if (m_curChar == 34)
JjCheckNAddStates(33, 35);
break;
case 5:
if (m_curChar == 34 && kind > 31)
kind = 31;
break;
case 6:
if ((0xfffffffeffffffffL & l) == (ulong)0L)
break;
if (kind > 32)
kind = 32;
JjCheckNAdd(6);
break;
default: break;
}
}
while (i != startsAt);
}
else if (m_curChar < 128)
{
ulong l = (ulong) (1L << (m_curChar & 63));
do
{
switch (jjstateSet[--i])
{
case 0:
case 6:
if ((0xdfffffffdfffffffL & l) == (ulong)0L)
break;
if (kind > 32)
kind = 32;
JjCheckNAdd(6);
break;
case 2:
JjAddStates(33, 35);
break;
case 4:
if (m_curChar == 92)
jjstateSet[jjnewStateCnt++] = 3;
break;
default: break;
}
}
while (i != startsAt);
}
else
{
int hiByte = (int) (m_curChar >> 8);
int i1 = hiByte >> 6;
ulong l1 = (ulong) (1L << (hiByte & 63));
int i2 = (m_curChar & 0xff) >> 6;
ulong l2 = (ulong) (1L << (m_curChar & 63));
do
{
switch (jjstateSet[--i])
{
case 0:
if (JjCanMove_0(hiByte, i1, i2, l1, l2))
{
if (kind > 7)
kind = 7;
}
if (JjCanMove_1(hiByte, i1, i2, l1, l2))
{
if (kind > 32)
kind = 32;
JjCheckNAdd(6);
}
break;
case 2:
if (JjCanMove_1(hiByte, i1, i2, l1, l2))
JjAddStates(33, 35);
break;
case 6:
if (!JjCanMove_1(hiByte, i1, i2, l1, l2))
break;
if (kind > 32)
kind = 32;
JjCheckNAdd(6);
break;
default: break;
}
}
while (i != startsAt);
}
if (kind != 0x7fffffff)
{
jjmatchedKind = kind;
jjmatchedPos = curPos;
kind = 0x7fffffff;
}
++curPos;
if ((i = jjnewStateCnt) == (startsAt = 7 - (jjnewStateCnt = startsAt)))
return curPos;
try
{
m_curChar = m_input_stream.ReadChar();
}
catch (Exception e) when (e.IsIOException())
{
return curPos;
}
}
}