intersection method

  1. @useCopy
ISet<T> intersection(
  1. Iterable<T> other
)

Returns a new set which is the intersection between this set and other.

That is, the returned set contains all the elements of this ISet that are also elements of other according to other.contains.

Implementation

@useCopy
ISet<T> intersection(Iterable<T> other) {
  Set<T> otherSet = _setFromIterable(other);
  return ISet._unsafeFromSet(_s.intersection(otherSet), config: config);
}