Skip to content

Commit d22dfe2

Browse files
committed
Enable -Xsource:3 in unidoc after disabling in mdoc
1 parent 9703081 commit d22dfe2

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

build.sbt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3218,6 +3218,7 @@ lazy val `microsite` = project.in(file("doc/microsite"))
32183218
} },
32193219
scalacOptions -= "-Wconf:any:error",
32203220
scalacOptions -= "-Xsource:3",
3221+
Compile / sbt.Keys.doc / scalacOptions += "-Xsource:3",
32213222
coverageEnabled := false,
32223223
publish / skip := true,
32233224
DocKeys.prefix := {if (isSnapshot.value) {

project/Deps.sc

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -582,7 +582,24 @@ object Izumi {
582582
depends = all.flatMap(_.artifacts).map(_.name in Scope.Compile.all).distinct,
583583
settings = Seq(
584584
"scalacOptions" -= "-Wconf:any:error",
585+
// Disable `-Xsource:3` in docs due to mdoc failures:
586+
//
587+
// ```
588+
// error: basics.md:97 (mdoc generated code) could not find implicit value for parameter t: pprint.TPrint[zio.ZIO[zio.Has[zio.console.Console.Service],Throwable,β$0$]]
589+
// val injector: Injector[RIO[Console, _]] = Injector[RIO[Console, _]](); $doc.binder(injector, 2, 4, 2, 12)
590+
// ^
591+
//
592+
// error: basics.md:109 (mdoc generated code) could not find implicit value for parameter t: pprint.TPrint[zio.ZIO[zio.Has[zio.console.Console.Service],Throwable,β$0$]]
593+
// val resource = injector.produce(plan); $doc.binder(resource, 4, 4, 4, 12)
594+
// ^
595+
//
596+
// error: basics.md:1359 (mdoc generated code) could not find implicit value for parameter t: pprint.TPrint[zio.ZIO[zio.Has[zio.console.Console.Service],Throwable,β$9$]]
597+
// val res51 = chooseInterpreters(true); $doc.binder(res51, 26, 0, 26, 24)
598+
// ```
585599
"scalacOptions" -= "-Xsource:3",
600+
// enable for unidoc
601+
"scalacOptions" in SettingScope.Raw("Compile / sbt.Keys.doc") += "-Xsource:3",
602+
//
586603
"coverageEnabled" := false,
587604
"skip" in SettingScope.Raw("publish") := true,
588605
"DocKeys.prefix" :=

0 commit comments

Comments
 (0)