
Please make your proposal more specific. (So that we can tear it apart, haha!) Seriously, I think it is to vague for starting a discussion. Best, Andreas On 24.03.2017 11:36, Merijn Verstraaten wrote:
I would like to propose adding a newtype wrapper (with all relevant instances) for Map and IntMap (if I missed any other applicable type in containers, let me know).
This newtype should differ in Monoid/Semigroup instance from Map/IntMap by switching:
Ord k => Semigroup (Map k v) Ord k => Monoid (Map k v)
to:
(Ord k, Semigroup v) => Semigroup (Map k v) (Ord k, Monoid v) => Monoid (Map k v) or (Ord k, Semigroup v) => Monoid (Map k v)
Any opinions on the overall idea? Opinions on which Monoid instance? Bikeshed for the newtype names?
Cheers, Merijn
_______________________________________________ Libraries mailing list Libraries@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
-- Andreas Abel <>< Du bist der geliebte Mensch. Department of Computer Science and Engineering Chalmers and Gothenburg University, Sweden andreas.abel@gu.se http://www.cse.chalmers.se/~abela/