@NotNull
  public static List<PsiElement> filterTopPriorityResults(ResolveResult @NotNull [] resolveResults) {
    if (resolveResults.length == 0) return Collections.emptyList();

    final int maxRate = getMaxRate(Arrays.asList(resolveResults));
    return StreamEx
      .of(resolveResults)
      .filter(resolveResult -> getRate(resolveResult) >= maxRate)
      .map(ResolveResult::getElement)
      .nonNull()
      .toList();
  }
@NotNull
  public static List<PsiElement> filterTopPriorityResults(ResolveResult @NotNull [] resolveResults)