docs: @SuppressWarnings("unchecked")
      public static <T> T[] toUnique(T[] self, Comparator<T> comparator) {
          Collection<T> items = toUnique(toList(self), comparator);
          T[] result = createSimilarArray(self, items.size());
          return items.toArray(result);
      }