Bunch v0.3.0 Bunch.TupleList View Source
A bunch of helper functions for manipulating lists of tuples (including keyword lists).
Link to this section Summary
Link to this section Functions
Link to this function
map_keys(list, f) View Source
Maps keys of list
using function f
.
Example
iex> Bunch.TupleList.map_keys([{1, :a}, {2, :b}], & &1+1)
[{2, :a}, {3, :b}]
Link to this function
map_values(list, f) View Source
Maps values of list
using function f
.
Example
iex> Bunch.TupleList.map_values([a: 1, b: 2], & &1+1)
[a: 2, b: 3]