spire
spire copied to clipboard
cats.kernel.CommutativeGroup instances for the various numeric types?
This plays into https://github.com/typelevel/algebra/issues/218. In the Cats ecosystem all numeric types (Int, Long, BigInt, BigDecimal, etc.) come with a default Group that does addition.
This is pretty useful as most of the time addition is what you want e.g. when using foldMap or combineAll and it's a bit of a shame we can't reuse existing code relying on these functions to "just work" with the spire numeric types.