View Source Iter.Iterable.Deduper (iterex v0.1.2)

An iterable that only emits elements if they are different from the previous element.

Summary

Functions

Creates an iterable that only emits elements if they are different from the previous element.

Types

@type t() :: %Iter.Iterable.Deduper{
  fun: (Iter.Iterable.element() -> any()),
  iterable: Iter.Iterable.t(),
  last_result: nil | Iter.Iterable.element()
}

Functions

Link to this function

new(iterable, fun \\ &Function.identity/1)

View Source

Creates an iterable that only emits elements if they are different from the previous element.