@Override
  public void processFoundElementForUpdatingParameterInfo(@Nullable PsiExpressionList expressionList, @NotNull UpdateParameterInfoContext context) {
    if (expressionList != null) {
      Object[] candidates = context.getObjectsToView();
      if (candidates != null && candidates.length != 0) {
        PsiElement parent = expressionList.getParent();

        int currentNumberOfParameters = expressionList.getExpressionCount();
        PsiDocumentManager psiDocumentManager = PsiDocumentManager.getInstance(context.getProject());
        Document document = psiDocumentManager.getCachedDocument(context.getFile());
        if (parent instanceof PsiCallExpression call && JavaMethodCallElement.isCompletionMode(call)) {
          PsiMethod chosenMethod = CompletionMemory.getChosenMethod(call);
          if ((context.getHighlightedParameter() != null || candidates.length == 1) && chosenMethod != null &&
              document != null && psiDocumentManager.isCommitted(document) &&
              isIncompatibleParameterCount(chosenMethod, currentNumberOfParameters)) {
            JavaMethodCallElement.setCompletionMode(call, false);
            // make sure the statement above takes effect
            asyncHighlightHints(context.getEditor(), null, -1, context.getCustomContext());
          }
          else {
            int index = ParameterInfoUtils.getCurrentParameterIndex(expressionList.getNode(),
                                                                    context.getOffset(), JavaTokenType.COMMA);
            TextRange textRange = expressionList.getTextRange();
            if (context.getOffset() <= textRange.getStartOffset() || context.getOffset() >= textRange.getEndOffset()) index = -1;
            asyncHighlightHints(context.getEditor(), expressionList, context.isInnermostContext() ? index : -1,
                                context.getCustomContext());
          }
        }
      }
    }
    else {
      asyncHighlightHints(context.getEditor(), null, -1, context.getCustomContext());
    }
  }
@Override
  public void processFoundElementForUpdatingParameterInfo(@Nullable PsiExpressionList expressionList, @NotNull UpdateParameterInfoContext context)