-
Notifications
You must be signed in to change notification settings - Fork 99
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expanded unionWith for different value types #488
Comments
That's what (EDIT: So if you are already using |
The case I was using was just one example which could use |
FWIW, https://hackage.haskell.org/package/containers-0.7/docs/Data-Map-Merge-Lazy.html#v:merge has in its docs
The
so the building blocks are there. |
|
Hi, I think there's space for a
unionWith
with a signature likeunionWith' :: Hashable k => (a -> c) -> (b -> c) -> (a -> b -> c) -> HM.HashMap k a -> HM.HashMap k b -> HM.HashMap k c
.This differs from the existing unionWith by allowing different ways to transforming the input maps, and being more specific in how to combine maps with differing value types.
My current usage is generally
HM.unionWith' This That These
. This would be a more powerful function.The text was updated successfully, but these errors were encountered: