[Haskell-cafe] common class for Set (and Map, resp.) implementations with different constraints on the keys

waldmann johannes.waldmann at htwk-leipzig.de
Fri Sep 7 18:12:25 UTC 2018


On 09/07/2018 05:51 PM, David Feuer wrote:

> class e ~ Elem s => SetC e s where

OK. At the use site, under both proposals,
there'll be a two argument constraint.
In my version, the second argument was curried away.

One way or the other - why don't we?
What could be the downsides here?

I guess since it's meant to sit atop (some) modules
from various packages (containers, unordered-containers, enummapset)
it's best to release it as a separate package,
containing the classes, and orphan instances.

- J.


More information about the Haskell-Cafe mailing list