You're seeing just the function remove, go back to Pfx module for more information.
Link to this function

remove(pfx, position, length)

View Source


remove(t(), non_neg_integer(), non_neg_integer()) :: t()

Removes length bits from pfx-s bitstring, starting at position.

A negative position is relative to the end of the pfx.bits-string. Valid range for position is -bit_size(pfx.bits) .. bit_size(pfx.bits)-1.

If length is positive, bits are removed to the right. If it is negative bits are removed going to the left.


  • length is silently clipped to the maximum number of bits available to remove
  • removing bits from pfx.bits does not change its pfx.maxlen


iex> remove("", 8, 8)

iex> remove("", -1, 1)

iex> remove("0288.88FF.FE88.8888", 24, 16)