offendingState property

int offendingState
getter/setter pair

Get the ATN state number the parser was in at the time the error occurred. For NoViableAltException and LexerNoViableAltException exceptions, this is the DecisionState number. For others, it is the state whose outgoing edge we couldn't match.

If the state number is not known, this method returns -1.

Implementation

int offendingState = -1;