-
-
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 F[TupleN]
syntax
#4125
Add F[TupleN]
syntax
#4125
Conversation
As I understand, the worst concern regarding changes like this one is a potential increase of the result jar size. Link to a similar PR: #4009 |
this seems like a PR for mouse if you ask me: https://github.com/typelevel/mouse which, BTW, I would live to see merged into this repo since I believe cats is the only dependency. Then it would just be a submodule here. |
@johnynek yeah, I was thinking about this, but it just confusing a bit to have |
Can we take yet another look at this? I have a concern about having this in the Mouse. It's just odd to have |
Yep, I agree with this. If this is the primary reason to target this PR to cats, maybe the real question is do
Possibly off-topic, but I haven't been able to appreciate why this is such a big deal. See my comments in #3871 (comment). But I would like to know if there's something I'm not getting :) |
Mouse is about six years this May :) And |
I see, those methods were added in #3318. |
I think in the past reviewers (such as me) did not think about mouse. Adding 1F, 2F also can be related to the idea that tuple2 is special: we do have tuple2 FlatMap for instance. We might not necessarily have TupleN FlatMap. I think considering Tuple2 as special, since it is kind of the primitive product type, but argue that in scala2, higher arities should go in mouse. But it is hard to draw a line on how much we want to trade off jar size for functionality. It would be interesting to consider how we could have a framework for these kinds of PRs. |
If we speak about the end-user experience it'd be totally bizarre to add a new library as a dependency to get syntaxes for TupleN (this and any future ones), as far I can see it. So if it's a clinched question for all these syntaxes, I won't make waves. |
This adds convenient
_1F
..._22F
methods forF[Tuple3..22]
. At the moment, Cats contains those methods only forF[Tuple2]
, so it would be great to have it for all Tuple families.I'm open to any suggestions/points about this.