Closed as not planned
Description
Compiler version
Last good release: 3.6.0-RC1-bin-20240719-af933c4-NIGHTLY
First bad release: 3.6.0-RC1-bin-20240723-46ff151-NIGHTLY
Bisect scripts failed to build the compiler for some revisions, the first bad commit could be any of:
3b3b8a7
637b1d3
2cfc561
875af44
dec395b
Minimized code
trait IO2[F[_, _]]:
def apply[A](effect: => A): F[Throwable, A] = ???
trait syntax:
def IO2[F[_, _], A](effect: => A)(implicit F: IO2[F]): F[Throwable, A] = ???
def IO2[F[_, _]: IO2]: IO2[F] = ???
class Test extends syntax:
class X[F[_, _]: IO2]:
def fails = IO2(println("hello world!"))
def works = IO2(println("hello world!"))(using summon[IO2[F]])
Output
[error] ./src/test.scala:10:17
[error] Ambiguous overload. The overloaded alternatives of method IO2 in trait syntax with types
[error] [F[_$5,_$6]](using evidence$1: IO2[F]): IO2[F]
[error] [F[_$3,_$4], A](effect: => A)(implicit F: IO2[F]): F[Throwable, A]
[error] both match arguments (Unit)
[error] def fails = IO2(println("hello world!"))
[error] ^^^
Expectation
Should compile