Closed
Description
Straight out of scala/bug#10753 (comment)
trait Bar[F[_]]
trait Foo[A]
trait Qux[A] extends Foo[A]
object Qux {
implicit def string: Qux[String] = ???
implicit def bar: Bar[Qux] = ???
}
case class Problem[A](a: A)
object Problem {
import Qux._
implicit def deriv[A, F[_]](implicit B: Bar[F], F: F[A]): F[Problem[A]] = ???
implicitly[Foo[Problem[String]]]
}
I don't know if this is the intended behaviour in Dotty, but I'm reporting it just in case. It looks like F
is instantiated to Foo
in Dotty but not in Scala, which is what scala/bug#10753 is all about. The code above is a counterexample (maybe it can be minimized further).