cats icon indicating copy to clipboard operation
cats copied to clipboard

implicit Tuple2K

Open johnynek opened this issue 5 years ago • 2 comments

It is useful in some contexts to have:

implicit def summonTuple2K[F[_], G[_], A](implicit fa: F[A], ga: G[A]): Tuple2K[F, G, A] =
  Tuple2K(fa, ga)

for cases where we are letting implicit resolution drive some computations.

Any reason this should not be in the companion for Tuple2K?

johnynek avatar May 11 '20 00:05 johnynek

I can't think of any harm in this. It's certainly not going to resolve the way you want it to in many cases, but for the cases where it doesn't resolve properly, I'm quite certain it doesn't break anything when it's on the companion.

djspiewak avatar Jun 04 '20 20:06 djspiewak

BTW: @djspiewak can you give an example of it this not resolving the way you want? This seems to me to be quite natural.

johnynek avatar Jul 02 '20 02:07 johnynek