-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add FunctorK trait #2697
Comments
@diesalbla FWIW, I don't think we need to close this immediatly, we could discuss this again :) |
As a quick intuition as to why this has historically been complicated… Higher-kinded arities get complicated very quickly. The It's kind of a mess. Poly kinds make this much nicer. Also if Scala had a kind system which didn't encode arities in the way it does, that would also make these sorts of things easier to generalize (since we wouldn't have to carry an explicit first-order-kinded type along as we climb the universes). |
@djspiewak thanks for the helpful summarization of the problem. I am going to refer to it at the |
There are several transformers and data types in
cats
and associated libraries that are parameterised on a kind-1 typeF[_]
and a kind-0 type parameterA
. For convenience, I called them the effect type and the value type, respectively. Some of these data types areNested
,EitherT
,OptionT
,OneAnd
,Kleisli
,Free
.In
cats-tagless
project defines a trait FunctorK, for types that provide amapK
method, which could be defined as follows:The proposal of this issue is to bring the definition of this
FunctorK
type-class into thecore
library, given that it would abstract an operation already in the library.The text was updated successfully, but these errors were encountered: