-- | Favours the first list as what value ends up in the result
mergeAssocLists :: (Eq a) => [(a, b)] -> [(a, b)] -> [(a, b)]
mergeAssocLists xs ys = nubBy ((==) `on` fst) (xs ++ ys)
mergeAssocLists :: (Eq a) => [(a, b)] -> [(a, b)] -> [(a, b)]
mergeAssocLists xs ys = nubBy ((==) `on` fst) (xs ++ ys)
mergeAssocLists xs ys = nubBy ((==) `on` fst) (xs ++ ys)