File tree Expand file tree Collapse file tree 2 files changed +14
-0
lines changed
src/library/scala/collection Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -142,6 +142,13 @@ sealed abstract class ArraySeq[+A]
142
142
}
143
143
144
144
override protected [this ] def writeReplace (): AnyRef = this
145
+
146
+ override def equals (other : Any ): Boolean = other match {
147
+ case that : ArraySeq [_] if this .unsafeArray.length != that.unsafeArray.length =>
148
+ false
149
+ case _ =>
150
+ super .equals(other)
151
+ }
145
152
}
146
153
147
154
/**
Original file line number Diff line number Diff line change @@ -77,6 +77,13 @@ abstract class ArraySeq[T]
77
77
}
78
78
79
79
override protected [this ] def writeReplace (): AnyRef = this
80
+
81
+ override def equals (other : Any ): Boolean = other match {
82
+ case that : ArraySeq [_] if this .array.length != that.array.length =>
83
+ false
84
+ case _ =>
85
+ super .equals(other)
86
+ }
80
87
}
81
88
82
89
/** A companion object used to create instances of `ArraySeq`.
You can’t perform that action at this time.
0 commit comments