Skip to content
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

Future-proof the collections for Dotty #7747

Merged
merged 3 commits into from
Feb 17, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/library/scala/collection/Map.scala
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,12 @@ trait MapOps[K, +V, +CC[_, _] <: IterableOps[_, AnyConstr, _], +C]
fromSpecific(this.view.filterKeys(k => !keysSet.contains(k)))
}

// The implicit dummy parameter is necessary to avoid erased signature clashes
// between this `++:` and the overload overriden below.
// Note that these clashes only happen in Dotty because it adds mixin
// forwarders before erasure unlike Scala 2.
@deprecated("Use ++ instead of ++: for collections of type Iterable", "2.13.0")
def ++: [V1 >: V](that: IterableOnce[(K,V1)]): CC[K,V1] = {
def ++: [V1 >: V](that: IterableOnce[(K,V1)])(implicit dummy: DummyImplicit): CC[K,V1] = {
val thatIterable: Iterable[(K, V1)] = that match {
case that: Iterable[(K, V1)] => that
case that => View.from(that)
Expand Down
2 changes: 1 addition & 1 deletion src/library/scala/concurrent/BatchingExecutor.scala
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ private[concurrent] object BatchingExecutorStatics {
// Max number of Runnables processed in one go (to prevent starvation of other tasks on the pool)
final val runLimit = 1024

final object MissingParentBlockContext extends BlockContext {
object MissingParentBlockContext extends BlockContext {
override def blockOn[T](thunk: => T)(implicit permission: CanAwait): T =
try thunk finally throw new IllegalStateException("BUG in BatchingExecutor.Batch: parentBlockContext is null")
}
Expand Down
15 changes: 0 additions & 15 deletions src/library/scala/runtime/package.scala

This file was deleted.