Pattern match a map Mar 3, 2016 Pattern match a map %{ b: value, d: value2 } = %{ a: 1, b: 2, d: 3 } # Matches keys on the left side # There may be more keys on the right side %{ a: value } = %{ a: 1, b: 2, d: 3 } # raises a match error if key is missing %{ c: value } = %{ a: 1, b: 2 }