DefaultErrorStrategy.nextTokensContext

This field is used to propagate information about the lookahead following the previous match. Since prediction prefers completing the current rule to error recovery efforts, error reporting may occur later than the original point where it was discoverable. The original context is used to compute the true expected sets as though the reporting occurred as early as possible.

class DefaultErrorStrategy
protected
ParserRuleContext nextTokensContext;

Meta