Skip to content

Commit 3cd49e7

Browse files
Try to add 2.13.0-M5 support
1 parent 7857e41 commit 3cd49e7

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

build.sbt

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ scalaModuleSettings
44

55
scalaVersionsByJvm in ThisBuild := {
66
val v212 = "2.12.6"
7-
val v213 = "2.13.0-M3"
7+
val v213 = "2.13.0-M5"
88

99
val allFalse = List(v212 -> false, v213 -> false)
1010
Map(

src/main/scala/scala/async/internal/LiveVariables.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ trait LiveVariables {
185185
*/
186186

187187
var LVentry = IntMap[Set[Symbol]]() withDefaultValue Set[Symbol]()
188-
var LVexit = IntMap[Set[Symbol]]() withDefaultValue Set[Symbol]()
188+
var LVexit: Map[Int, Set[Symbol]] = IntMap[Set[Symbol]]() withDefaultValue Set[Symbol]()
189189

190190
// All fields are declared to be dead at the exit of the final async state, except for the ones
191191
// that cannot be nulled out at all (those in noNull), because they have been captured by a nested def.

src/test/scala/scala/async/run/futures/FutureSpec.scala

+4-3
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@ package scala.async
66
package run
77
package futures
88

9-
import scala.language.postfixOps
9+
import java.util.concurrent.ConcurrentHashMap
1010

11+
import scala.language.postfixOps
1112
import scala.concurrent._
1213
import scala.concurrent.duration._
1314
import scala.concurrent.duration.Duration.Inf
@@ -34,10 +35,10 @@ class FutureSpec {
3435
/* future specification */
3536

3637
@Test def `A future with custom ExecutionContext should handle Throwables`(): Unit = {
37-
val ms = new mutable.HashSet[Throwable] with mutable.SynchronizedSet[Throwable]
38+
val ms = new ConcurrentHashMap[Throwable, Unit]
3839
implicit val ec = scala.concurrent.ExecutionContext.fromExecutor(new java.util.concurrent.ForkJoinPool(), {
3940
t =>
40-
ms += t
41+
ms.put(t, ())
4142
})
4243

4344
class ThrowableTest(m: String) extends Throwable(m)

0 commit comments

Comments
 (0)