Names for general merge tactics in Data.Map
Henning Thielemann
lemming at henning-thielemann.de
Thu Aug 18 20:46:48 UTC 2016
On Thu, 18 Aug 2016, David Feuer wrote:
> I am open to the idea of leaving mergeWithKey in, but I'm not yet
> convinced. Can you give an example of a realistic application of
> mergeWithKey that cannot easily be rewritten in terms of generalMerge?
> I would normally agree with you that backwards compatibility should be
> preserved. However, mergeWithKey has several very serious problems.
In the past, it caused problems to install a new 'containers' on an old
GHC. Is this problem solved?
> 1. It allows the user to produce invalid maps. Unlike other functions
> that do so, it's not clear that it offers any significant efficiency
> benefit (once generalMerge is added).
How about adding WARNING or DEPRECATED?
More information about the Libraries
mailing list