Open Facsimiler opened 7 years ago
I'm having the same problem, both in Scala 2.11.8 and 2.12.1. My error looks slightly different:
[info] Main Scala API documentation to /home/hhrutz/Documents/devel/Mellite/site/target/scala-2.12/unidoc...
[error] /home/hhrutz/.sbt/0.13/staging/826f0b08a174143cc2c0/mellite/src/main/scala-2.12/de/sciss/mellite/gui/impl/FScapeOutputsViewImpl.scala:106: can't expand macros compiled by previous versions of Scala
[error] if (res === OptionPane.Result.Ok) {
[error] ^
[error] /home/hhrutz/.sbt/0.13/staging/826f0b08a174143cc2c0/mellite/src/main/scala/de/sciss/mellite/ProcActions.scala:133: can't expand macros compiled by previous versions of Scala
[error] if (key !== Proc.mainIn) {
[error] ^
[error] /home/hhrutz/.sbt/0.13/staging/826f0b08a174143cc2c0/mellite/src/main/scala/de/sciss/mellite/gui/ActionArtifactLocation.scala:86: can't expand macros compiled by previous versions of Scala
[error] if (optRes === 0) {
[error] ^
In my case, adding scala-reflect to the unidoc project solved the issue for me:
+ libraryDependencies ++= Seq(
+ "org.scala-lang" % "scala-reflect" % scalaVersion.value % "provided"
+ ),
I just revisited this issue, which is still present in Scala 2.12.8, and found that if I remove the -implicits
flag, the assertion error no longer occurs.
@Sciss It appears that our issues are different. I tried adding the scala-reflect
dependency, and it made no difference.
Hi!
I recently switched to using Scala 2.12, and have since found that Unidoc fails when processing sources containing macro definitions. Specifically, an assertion error results.
The
Ymacro-no-expand
option has been deprecated in favor ofYmacro-expand:none
as of Scala 2.12, so I'm using that, but otherwise, there aren't too many changes I can recall from the sources I used with Scala 2.11.Unidoc worked fine with the same code under Scala 2.12. Am I missing something?
Here's what I'm seeing:
This is then followed by a repeat of the original error message heading, without the stack trace. I'm not sure what line of the file is causing the failure.
Any ideas?
UPDATE: Incidentally, if I generate documentation using "doc" instead, I don't get any errors.