A.Vector.reject

You're seeing just the function reject, go back to A.Vector module for more information.

Specs

reject(t(val), (val -> as_boolean(term()))) :: t(val) when val: value()

Filters the vector, i.e. return a new vector containing only elements for which fun returns a falsy (either false or nil) value.

Runs in linear time.

Examples

iex> vector = A.Vector.new(1..12)
iex> A.Vector.reject(vector, fn i -> rem(i, 3) == 0 end)
vec([1, 2, 4, 5, 7, 8, 10, 11])