Skip to content

Commit f08114e

Browse files
committed
fix: fix when compiling with 2.12
1 parent 5776a32 commit f08114e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

actor/src/main/scala/org/apache/pekko/dispatch/VirtualThreadSupportReflect.scala

+2-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,8 @@ private[dispatch] object VirtualThreadSupportReflect {
5555
}
5656
val nameMethod = ofVirtualClass.getDeclaredMethod("name", classOf[String], classOf[Long])
5757
val factoryMethod = builderClass.getDeclaredMethod("factory")
58-
builder = nameMethod.invoke(builder, prefix + "-virtual-thread-", 0L)
58+
val zero = java.lang.Long.valueOf(0L)
59+
builder = nameMethod.invoke(builder, prefix + "-virtual-thread-", zero)
5960
factoryMethod.invoke(builder).asInstanceOf[ThreadFactory]
6061
} catch {
6162
case NonFatal(e) =>

0 commit comments

Comments
 (0)