@Contract("null, _, _ -> false")
  private static boolean isNonResolvedTypeParameter(@Nullable PsiClass parameter,
                                                    @NotNull PsiElement context,
                                                    @NotNull PsiResolveHelper resolveHelper) {
    if (!(parameter instanceof PsiTypeParameter typeParameter)) return false;
    String name = typeParameter.getName();
    return name == null || resolveHelper.resolveReferencedClass(name, context) != parameter;
  }
@Contract("null, _, _ -> false")
  private static boolean isNonResolvedTypeParameter(@Nullable PsiClass parameter,
                                                    @NotNull PsiElement context,
                                                    @NotNull PsiResolveHelper resolveHelper)