We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5f88058 + b57cd71 commit 75f7cb3Copy full SHA for 75f7cb3
library/src/scala/runtime/Tuples.scala
@@ -58,6 +58,7 @@ object Tuples {
58
else TupleXXL.fromIArray(xs).asInstanceOf[Tuple]
59
60
def fromProduct(xs: Product): Tuple = (xs.productArity match {
61
+ case 0 => EmptyTuple
62
case 1 =>
63
xs match {
64
case xs: Tuple1[_] => xs
tests/run/i11793.scala
@@ -0,0 +1,2 @@
1
+case class Foo()
2
+@main def Test: Unit = Tuple.fromProduct(Foo())
0 commit comments