diff --git a/.scalafmt.conf b/.scalafmt.conf index 82ae6704f..6e2cf3422 100644 --- a/.scalafmt.conf +++ b/.scalafmt.conf @@ -1,5 +1,5 @@ version = "3.2.1" -runner.dialect = scala213 +runner.dialect = scala213source3 maxColumn = 100 project.git = true align.preset = none diff --git a/build.sbt b/build.sbt index 9c3450c1c..daed20177 100644 --- a/build.sbt +++ b/build.sbt @@ -94,6 +94,8 @@ inThisBuild( packageDoc / publishArtifact := "true" == System.getenv("CI"), packageSrc / publishArtifact := "true" == System.getenv("CI"), turbo := true, + semanticdbEnabled := true, + semanticdbVersion := "4.4.31", useSuperShell := false // overlaps with MUnit test failure reports. ) ) diff --git a/mdoc/src/main/scala-2/mdoc/internal/markdown/MarkdownCompiler.scala b/mdoc/src/main/scala-2/mdoc/internal/markdown/MarkdownCompiler.scala index 7c6b3384c..272d987f5 100644 --- a/mdoc/src/main/scala-2/mdoc/internal/markdown/MarkdownCompiler.scala +++ b/mdoc/src/main/scala-2/mdoc/internal/markdown/MarkdownCompiler.scala @@ -30,6 +30,7 @@ import scala.annotation.implicitNotFound import mdoc.internal.CompatClassloader import mdoc.internal.worksheets.Compat._ import scala.meta.internal.inputs._ +import scala.tools.nsc.plugins.Plugin class MarkdownCompiler( classpath: String, @@ -52,7 +53,13 @@ class MarkdownCompiler( def classpathEntries: Seq[Path] = global.classPath.asURLs.map(url => Paths.get(url.toURI())) private val sreporter = new FilterStoreReporter(settings) - var global = new Global(settings, sreporter) + var global = new Global(settings, sreporter) { + // Disable the SemanticDB compiler plugin because it's not needed for + // Markdown evaluation. The primary motivation to disable the SemanticDB + // compiler plugin was to work around this bug here + // https://github.com/scalameta/scalameta/pull/2528 + override protected def loadPlugins(): List[Plugin] = super.loadPlugins().filterNot(_.name == "semanticdb") + } private def reset(): Unit = { global = new Global(settings, sreporter) } diff --git a/project/build.properties b/project/build.properties index baf5ff3ec..3161d2146 100644 --- a/project/build.properties +++ b/project/build.properties @@ -1 +1 @@ -sbt.version=1.5.7 +sbt.version=1.6.1