diff options
author | Janek Bogucki <janekdb@gmail.com> | 2015-10-07 20:32:49 +0100 |
---|---|---|
committer | Janek Bogucki <janekdb@gmail.com> | 2015-10-09 20:07:19 +0100 |
commit | b19a07ed15f8a633e0463e52839c956963a9c2f9 (patch) | |
tree | 43840caeaebc12e2c40d8620b1de579ad7529a83 /src/library/scala/collection/parallel | |
parent | 648c7a1635f88fb14b999a8d36e01a71761b9001 (diff) | |
download | scala-b19a07ed15f8a633e0463e52839c956963a9c2f9.tar.gz scala-b19a07ed15f8a633e0463e52839c956963a9c2f9.tar.bz2 scala-b19a07ed15f8a633e0463e52839c956963a9c2f9.zip |
Rename forall, exists and find predicate and operator params.
Align parameters names to use p for predicates and op for combining operations.
Based on #4760. Extended to include,
- Tuple2Zipped
- Tuple3Zipped
- Either
The original author was vsalvis.
Diffstat (limited to 'src/library/scala/collection/parallel')
-rw-r--r-- | src/library/scala/collection/parallel/ParIterableLike.scala | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/library/scala/collection/parallel/ParIterableLike.scala b/src/library/scala/collection/parallel/ParIterableLike.scala index 016255dca4..e7b022b895 100644 --- a/src/library/scala/collection/parallel/ParIterableLike.scala +++ b/src/library/scala/collection/parallel/ParIterableLike.scala @@ -520,22 +520,22 @@ self: ParIterableLike[T, Repr, Sequential] => * * $abortsignalling * - * @param pred a predicate used to test elements + * @param p a predicate used to test elements * @return true if `p` holds for all elements, false otherwise */ - def forall(pred: T => Boolean): Boolean = { - tasksupport.executeAndWaitResult(new Forall(pred, splitter assign new DefaultSignalling with VolatileAbort)) + def forall(@deprecatedName('pred) p: T => Boolean): Boolean = { + tasksupport.executeAndWaitResult(new Forall(p, splitter assign new DefaultSignalling with VolatileAbort)) } /** Tests whether a predicate holds for some element of this $coll. * * $abortsignalling * - * @param pred a predicate used to test elements + * @param p a predicate used to test elements * @return true if `p` holds for some element, false otherwise */ - def exists(pred: T => Boolean): Boolean = { - tasksupport.executeAndWaitResult(new Exists(pred, splitter assign new DefaultSignalling with VolatileAbort)) + def exists(@deprecatedName('pred) p: T => Boolean): Boolean = { + tasksupport.executeAndWaitResult(new Exists(p, splitter assign new DefaultSignalling with VolatileAbort)) } /** Finds some element in the collection for which the predicate holds, if such @@ -546,11 +546,11 @@ self: ParIterableLike[T, Repr, Sequential] => * * $abortsignalling * - * @param pred predicate used to test the elements + * @param p predicate used to test the elements * @return an option value with the element if such an element exists, or `None` otherwise */ - def find(pred: T => Boolean): Option[T] = { - tasksupport.executeAndWaitResult(new Find(pred, splitter assign new DefaultSignalling with VolatileAbort)) + def find(@deprecatedName('pred) p: T => Boolean): Option[T] = { + tasksupport.executeAndWaitResult(new Find(p, splitter assign new DefaultSignalling with VolatileAbort)) } /** Creates a combiner factory. Each combiner factory instance is used |