Closed
Description
Based on OpenCB failure in katrix/dataprism
- build logs
Compiler version
Last good release: 3.6.0-RC1-bin-20240922-22ed2fb-NIGHTLY
First bad release: 3.6.0-RC1-bin-20240923-e5f7272-NIGHTLY
Bisect points to 9f90ad0
Minimized code
sealed abstract class Gen[+T]
given [T]: Conversion[T, Gen[T]] = ???
trait Show[T]
given Show[Boolean] = ???
given [A: Show, B: Show, C: Show]: Show[(A, B, C)] = ???
object ForAll:
def apply[A1: Show, B](f: A1 => B): Unit = ???
def apply[A1: Show, A2: Show, B](f: (A1, A2) => B): Unit = ???
def apply[A: Show, B](gen: Gen[A])(f: A => B): Unit = ???
@main def Test =
ForAll: (b1: Boolean, b2: Boolean, b3: Boolean) =>
???
Output
[error] ./test.scala:13:8
[error] No given instance of type Show[(Boolean, Boolean, Boolean) => Nothing] was found for a context parameter of method apply in object ForAll
[error] ???
Expectation
Should compile
Case 2
object ForAll:
def apply[A1, B](f: A1 => B): Unit = ???
def apply[A1, A2, B](f: (A1, A2) => B): Unit = ???
@main def Test =
ForAll: (b1: Boolean, b2: Boolean, b3: Boolean) =>
???
[error] ./test.scala:21:3
[error] None of the overloaded alternatives of method apply in object ForAll with types
[error] [A1, A2, B](f: (A1, A2) => B): Unit
[error] [A1, B](f: A1 => B): Unit
[error] match arguments ((Boolean, Boolean, Boolean) => Nothing)
[error]
[error] where: A1 is a type variable
[error] A2 is a type variable
[error] B is a type variable
[error] ForAll: (b1: Boolean, b2: Boolean, b3: Boolean) =>
[error] ^^^^^^