-
Notifications
You must be signed in to change notification settings - Fork 30
fix: update parent type of ParSeqLike
#308
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Starting from Scala 3.8.0, the following code will not compile due to removing some unsound typing rules. See scala/scala3#23441 Co-authored-by: Eugene Flesselle <eugene@flesselle.net>
|
@SethTisue Can you please assign one of the maintainers as a reviewer for this PR. Thanks. |
|
review by @scala/collections ...? |
| * operation of `ParallelIterable` trait using the new `split` operation. | ||
| */ | ||
| trait ParSeqLike[+T, +CC[X] <: ParSeq[X], +Repr <: ParSeq[T], +Sequential <: scala.collection.Seq[T] with SeqOps[T, AnyConstr, Sequential]] | ||
| trait ParSeqLike[+T, +CC[X] <: ParSeq[X], +Repr <: ParSeq[T], +Sequential <: scala.collection.Seq[T] with SeqOps[T, collection.Seq, Sequential]] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not CC here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because we are putting constraints over the sequential type, not the parallel one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, this is just the right signature to have since Seq expects to have at least a Seq there. Same is done for ParIterableLike:
scala-parallel-collections/core/src/main/scala/scala/collection/parallel/ParIterableLike.scala
Line 147 in faac62a
| trait ParIterableLike[+T, +CC[X] <: ParIterable[X], +Repr <: ParIterable[T], +Sequential <: Iterable[T] with IterableOps[T, Iterable, Sequential @uncheckedVariance]] |
He-Pin
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Starting from Scala 3.8.0, the following code will not compile due to removing some unsound typing rules. See scala/scala3#23441 for more details.