Georgi Krastev
Georgi Krastev
But the tests are full of such algebras with two annotations and no companion objects: https://github.com/typelevel/cats-tagless/blob/master/tests/src/test/scala/cats/tagless/tests/autoFunctorKTests.scala Could it be something related to incremental compilation? Can you try to clean and...
Would this fix the problem? scala/scala#9555
To be honest I always wondered if that is better or worse. What if the instance itself incurs allocations (`implicit def`), wouldn't we then allocate it twice?
@kubukoz I mean that for each call we will allocate `Foldable` (if it's an `implicit def`) twice rather than once: ```scala catsSyntaxFoldOps(foo)(foldable1).fold(foldable2, monoid) ``` And I tend to agree that...
It's very tricky to explain when "you should use `map(_ => x)` instead of `as(x)`".
AFAIR the reason to not add these laws was the required implicit Order and the binary compatibility of the test-kit.
That's a good point. I've thought about it. It's also trivial to convert a trait with methods to a case class with functions. But I guess it's way more popular...
Ah, I just realized that shapeless doesn't have `Generic` for this kind of case classes. It has `Generic` for kind `*` and `Generic1` for kind `* -> *` but not...
> I am on my phone, but IIRC fully refined instance is not usable when an instance for the existential type (i.e. not fully refined) is expected, because FunctorK is...
Unfortunately this is mostly useful only for Scala 3