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.
1 parent c8ee991 commit 38f5cb7Copy full SHA for 38f5cb7
src/library/scala/Array.scala
@@ -574,9 +574,9 @@ object Array {
574
* @param x the selector value
575
* @return sequence wrapped in a [[scala.Some]], if `x` is an Array, otherwise `None`
576
*/
577
- def unapplySeq[T](x: Array[T]): UnapplySeqWrapper[T] = new UnapplySeqWrapper(x)
+ def unapplySeq[T](x: Array[_ <: T]): UnapplySeqWrapper[T] = new UnapplySeqWrapper(x)
578
579
- final class UnapplySeqWrapper[T](private val a: Array[T]) extends AnyVal {
+ final class UnapplySeqWrapper[T](private val a: Array[_ <: T]) extends AnyVal {
580
def isEmpty: false = false
581
def get: UnapplySeqWrapper[T] = this
582
def lengthCompare(len: Int): Int = a.lengthCompare(len)
0 commit comments