Cats: Map and SortedMap should have MonoidK instances

Created on 31 Jan 2019  路  7Comments  路  Source: typelevel/cats

Map#++ is associative and should also form a Monoid with Map.empty as the identity :)

help wanted low-hanging fruit

All 7 comments

One thing to note is that this one needs to follow the MapInstancesBinCompat0 example - i.e.

  1. Create a new MapInstancesBinCompat1 trait and add the instance there,
  2. find all usages of MapInstancesBinCompat0 and add MapInstancesBinCompat1 there.
  3. add 2 instance tests to cats.tests.MapSuite

I would like to take that one :)

Hey @wojciechUrbanski! Do you mind If I take this from you?

Hey @alexeygorobets. Sure, go on. Unfortunately i am a little bit occupied right now and cannot continue working on this one.

Thank you @wojciechUrbanski !

hi @kailuowang
Am I correct that I need to create a separate trait
trait AllInstancesBinCompat4 extends SortedMapInstancesBinCompat1 with MapInstancesBinCompat1
for maintaining binary compatibility?

@alexeygorobets that's correct. Thanks!

Fixed by #2744.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

diesalbla picture diesalbla  路  4Comments

kailuowang picture kailuowang  路  3Comments

julien-truffaut picture julien-truffaut  路  3Comments

alexandru picture alexandru  路  4Comments

mcanlas picture mcanlas  路  4Comments