What do people think of adding typeclasses that only add new laws (ie. have no new functionality, but restrict which implementations are valid.)
I'm specifically thinking of something like CommutativeMonad, which would add a commutativity restriction to Monad (so that e.g. a distributive law can be derived which would allow composition, see #332 and the related discussion re: Traverse).
Since we have discipline, the extra laws can be checked by implementers fairly easily, and it opens up new avenues for writing slightly more general combinators in cats.
What do people think of adding typeclasses that only add new laws (ie. have no new functionality, but restrict which implementations are valid.)
I'm specifically thinking of something like CommutativeMonad, which would add a commutativity restriction to Monad (so that e.g. a distributive law can be derived which would allow composition, see #332 and the related discussion re: Traverse).
Since we have discipline, the extra laws can be checked by implementers fairly easily, and it opens up new avenues for writing slightly more general combinators in cats.