protected override DFAState GetExistingTargetState(DFAState previousD, int t)
{
// this method is called after each time the input position advances
// during SLL prediction
sllStopIndex = input.Index;
DFAState existingTargetState = base.GetExistingTargetState(previousD, t);
if (existingTargetState != null)
{
decisions[currentDecision].SLL_DFATransitions++; // count only if we transition over a DFA state
if (existingTargetState == ERROR)
{
decisions[currentDecision].errors.Add(
new ErrorInfo(currentDecision, null /*previousD.configs*/, input, startIndex, sllStopIndex)
);
}
}
currentState = existingTargetState;
return existingTargetState;
}