From 7e417deeb7219a3b66ee9fdf0c31fe923d5c9658 Mon Sep 17 00:00:00 2001 From: kenji yoshida <6b656e6a69@gmail.com> Date: Sun, 30 Jun 2024 09:21:06 +0900 Subject: [PATCH] `-Xsource:3-cross` --- build.sbt | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/build.sbt b/build.sbt index 569db7c..894ba96 100644 --- a/build.sbt +++ b/build.sbt @@ -54,7 +54,14 @@ scalacOptions ++= Seq( ) scalacOptions ++= PartialFunction.condOpt(CrossVersion.partialVersion(scalaVersion.value)){ - case Some((2, v)) if v >= 11 => Seq("-Ywarn-unused", "-Xsource:3") + case Some((2, v)) if v >= 11 => Seq("-Ywarn-unused") +}.toList.flatten + +scalacOptions ++= PartialFunction.condOpt(CrossVersion.partialVersion(scalaVersion.value)){ + case Some((2, 11 | 12)) => + Seq("-Xsource:3") + case Some((2, 13)) => + Seq("-Xsource:3-cross") }.toList.flatten Test / sources := {