diff options
author | Rex Kerr <ichoran@gmail.com> | 2014-02-13 16:28:36 -0800 |
---|---|---|
committer | Rex Kerr <ichoran@gmail.com> | 2014-02-18 03:37:00 -0800 |
commit | 9be10bc084e8da77a773d6736c6a232ecd40b0c0 (patch) | |
tree | 02a3ee555eaa4aff9af89305f0863b26db0d097a /test/files | |
parent | 8536c3148d5a6283b580a905ca4231e852525d59 (diff) | |
download | scala-9be10bc084e8da77a773d6736c6a232ecd40b0c0.tar.gz scala-9be10bc084e8da77a773d6736c6a232ecd40b0c0.tar.bz2 scala-9be10bc084e8da77a773d6736c6a232ecd40b0c0.zip |
SI-8072 rationalize public implicits in scala parallel collections
Pretty much everything seems like it's intended for internal use, so I moved it to a package-private object.
Split toParArray out and put it in an implicit class. Added ability to .toParArray from Array and String also.
Added test to verify implicits are gone.
Diffstat (limited to 'test/files')
-rw-r--r-- | test/files/neg/t8072.check | 4 | ||||
-rw-r--r-- | test/files/neg/t8072.scala | 6 |
2 files changed, 10 insertions, 0 deletions
diff --git a/test/files/neg/t8072.check b/test/files/neg/t8072.check new file mode 100644 index 0000000000..9267010135 --- /dev/null +++ b/test/files/neg/t8072.check @@ -0,0 +1,4 @@ +t8072.scala:4: error: value ifParSeq is not a member of List[Int] + val y = x.ifParSeq[Int](throw new Exception).otherwise(0) // Shouldn't compile + ^ +one error found diff --git a/test/files/neg/t8072.scala b/test/files/neg/t8072.scala new file mode 100644 index 0000000000..2c8213e34a --- /dev/null +++ b/test/files/neg/t8072.scala @@ -0,0 +1,6 @@ +class NoIfParSeq { + import collection.parallel._ + val x = List(1,2) + val y = x.ifParSeq[Int](throw new Exception).otherwise(0) // Shouldn't compile + val z = x.toParArray +}
\ No newline at end of file |