private void popState(int currentState) {
    if (yystate() == currentState) {
      assert !stateStack.empty() : "States stack is empty";
      yybegin(stateStack.pop());
    }
  }
private void popState(int currentState)