diff options
author | Mark Zitnik <mark.zitnik@gmail.com> | 2015-01-18 18:34:15 +0200 |
---|---|---|
committer | Mark Zitnik <mark.zitnik@gmail.com> | 2015-01-18 18:34:15 +0200 |
commit | fb043761806f8ef2c7a662f15ba5ac5731426dbf (patch) | |
tree | fbda68065784bdffb3595ec6a2c13b4fda1e2775 /src/library | |
parent | d395e52eb1aad201746d978e31a350756d846614 (diff) | |
download | scala-fb043761806f8ef2c7a662f15ba5ac5731426dbf.tar.gz scala-fb043761806f8ef2c7a662f15ba5ac5731426dbf.tar.bz2 scala-fb043761806f8ef2c7a662f15ba5ac5731426dbf.zip |
SI-9072 Vector ++ concatenation of parallel collection cause inconsistent results
Diffstat (limited to 'src/library')
-rw-r--r-- | src/library/scala/collection/immutable/Vector.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/library/scala/collection/immutable/Vector.scala b/src/library/scala/collection/immutable/Vector.scala index c7da447f72..47a623a616 100644 --- a/src/library/scala/collection/immutable/Vector.scala +++ b/src/library/scala/collection/immutable/Vector.scala @@ -215,7 +215,7 @@ override def companion: GenericCompanion[Vector] = Vector import Vector.{Log2ConcatFaster, TinyAppendFaster} if (that.isEmpty) this.asInstanceOf[That] else { - val again = if (!that.isTraversableAgain) that.toVector else that + val again = if (!that.isTraversableAgain) that.toVector else that.seq again.size match { // Often it's better to append small numbers of elements (or prepend if RHS is a vector) case n if n <= TinyAppendFaster || n < (this.size >> Log2ConcatFaster) => |