[Haskell-cafe] Restricted type classes

Ivan Lazar Miljenovic ivan.miljenovic at gmail.com
Wed Sep 8 22:23:23 EDT 2010

On 9 September 2010 12:10, wren ng thornton <wren at freegeek.org> wrote:
> I think the shape of the classes for singletons, insert, coinsert, and union
> still needs some work. For instance, the definitions I've given earlier were
> assuming a (multi)set-like or sequence-like container, but we can also
> reasonably extend it to include map-like containers. The only trick is that
> set/seq-like containers have a single type parameter and a single element
> argument, whereas map-like containers have a pair of type parameters and a
> key--value pair of "elements". So we'd need to do something with MPTCs in
> order to unify them.

Yes, I'm not sure if Map-like types of kind * -> * -> * should have a
"value" of type (a,b) or then have BiFunctor, BiBuildable, etc.

Ivan Lazar Miljenovic
Ivan.Miljenovic at gmail.com

More information about the Haskell-Cafe mailing list