Closed
Description
Comment stolen from paulp’s explanation:
It should fail the compile with error: case classes without a parameter list are not allowed but the implicit parameter list fools it. Then it proceeds to act in a very confused manner, for instance turning all the explicitly written implicit parameters into case accessors.
scala> case class Bip(implicit x: Int, y: Int)
defined class Bip
scala> Bip()(1, 2).productArity
res4: Int = 2
But naturally it eventually inserts the empty parameter list, as seen above. Whereas:
scala> case class Bip2()(implicit x: Int, y: Int)
defined class Bip2
scala> Bip2()(1, 2).productArity
res5: Int = 0