Skip to content

Commit d1af68d

Browse files
committed
diagnostics rules are now resilient to Wconf silencing on LTS
#2275
1 parent fb8d71d commit d1af68d

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

build.sbt

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,16 @@ lazy val input = projectMatrix
250250
coverageEnabled := false,
251251
// mimic dependsOn(shared) but allowing binary Scala version matching
252252
Compile / internalDependencyClasspath ++=
253-
resolve(shared, Compile / exportedProducts).value
253+
resolve(shared, Compile / exportedProducts).value,
254+
scalacOptions ++= {
255+
// exercise https://github.com/scala/scala3/pull/23587
256+
scalaVersion.value match {
257+
case v if v.startsWith("2.") => Seq() // E198 not available on 2.x
258+
case v if v.startsWith("3.5") || v.startsWith("3.6") => Seq() // EOL
259+
case "3.7.2" => Seq() // version anterior to the fix
260+
case _ => Seq("-Wconf:id=E198:info")
261+
}
262+
}
254263
)
255264
.defaultAxes(VirtualAxis.jvm)
256265
.jvmPlatformTargets(cliScalaVersionsWithTargets.map(_._2))

0 commit comments

Comments
 (0)