Skip to content
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

Could not find proxy for implicit val (2.13.0) #11732

Open
djspiewak opened this issue Sep 10, 2019 · 0 comments

Comments

@djspiewak
Copy link

commented Sep 10, 2019

Lines in question:

  checkAllAsync("IO", implicit ec => {
    implicit val cs = ec.contextShift[IO]
    ParallelTests[IO, IO.Par].parallel[Int, Int]
  })

This also fails:

  checkAllAsync("IO", implicit ec => {
    implicit val cs = ec.contextShift[IO]
    ParallelTests[IO].parallel[Int, Int]
  })

This compiles successfully:

  checkAllAsync("IO", implicit ec => {
    implicit val cs = ec.contextShift[IO]

    // do NOT inline this val; it causes the 2.13.0 compiler to crash for... reasons
    val module = ParallelTests[IO]
    module.parallel[Int, Int]
  })

We discovered this when trying to release Cats Effect 2.0. Feels minimizeable but it's hard to say right now. The definition of ParallelTests (the object) is the following:

object ParallelTests {
  type Aux[M[_], F0[_]] = ParallelTests[M] { type F[A] = F0[A]; val laws: ParallelLaws.Aux[M, F0] }

  def apply[M[_]](implicit ev: Parallel[M]): ParallelTests.Aux[M, ev.F] =
    apply[M, ev.F](ev, implicitly)

  def apply[M[_], F[_]](implicit ev: Parallel.Aux[M, F], D: DummyImplicit): ParallelTests.Aux[M, F] =
    new ParallelTests[M] { val laws = ParallelLaws[M] }
}

Sorry for not minimizing. Just wanted to report first and pare it down later.

djspiewak added a commit to djspiewak/cats-effect that referenced this issue Sep 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.