public static List<PsiElement> filter(PsiElement[] elements, NodeSpecificHasherBase hasher) {
    List<PsiElement> filteredElements = new ArrayList<>();
    for (PsiElement element : elements) {
      if (!hasher.getNodeFilter().accepts(element)) {
        filteredElements.add(element);
      }
    }
    return filteredElements;
  }
public static List<PsiElement> filter(PsiElement[] elements, NodeSpecificHasherBase hasher)