Skip to content

Commit 48d2349

Browse files
Tuple.toList uses productIterator
1 parent 1f6fc97 commit 48d2349

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

library/src/scala/Tuple.scala

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ sealed trait Tuple extends Product {
1313

1414
/** Create a copy this tuple as a List */
1515
inline def toList: List[Union[this.type]] =
16-
toArray.toList.asInstanceOf[List[Union[this.type]]]
16+
this.productIterator.toList
17+
.asInstanceOf[List[Union[this.type]]]
1718

1819
/** Create a copy this tuple as an IArray */
1920
inline def toIArray: IArray[Object] =

0 commit comments

Comments
 (0)