public void acceptElements(@NotNull List<? extends PsiElement> elements, @NotNull PsiElementVisitor elementVisitor) {
    List<? extends Class<?>> acceptingPsiTypes = getAcceptingPsiTypes(elementVisitor);
    acceptElements(elements, acceptingPsiTypes, element -> element.accept(elementVisitor));
  }
public void acceptElements(@NotNull List<? extends PsiElement> elements, @NotNull PsiElementVisitor elementVisitor)