You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you compile this file using dotc then run it using dotr -with-compiler testthething.Main everything is fine. If however you open a REPL using dotr -with-compiler then try to call the same method explicitly as in testthething.Main.main(Array()) it crashes spectacularly:
scala> testthething.Main.main(Array())
Bad symbolic reference. A signature
refers to testthething[ModuleClass]/T in package <root> which is not available.
It may be completely missing from the current classpath, or the version on
the classpath might be incompatible with the version used when compiling the signature.
java.lang.Exception: Could not extract Expr(<pickled tasty>)
at dotty.tools.dotc.quoted.QuoteDriver.withTree$$anonfun$2(QuoteDriver.scala:65)
at scala.Option.getOrElse(Option.scala:138)
at dotty.tools.dotc.quoted.QuoteDriver.withTree(QuoteDriver.scala:65)
at dotty.tools.dotc.quoted.QuoteDriver.show(QuoteDriver.scala:53)
at dotty.tools.dotc.quoted.ToolboxImpl$$anon$1.show(ToolboxImpl.scala:25)
at scala.quoted.Expr.show(Expr.scala:16)
at testthething.Main$.main(Test.scala:8)
at rs$line$1$.<init>(rs$line$1:1)
[abridged]
This seems related somehow to the T in Option[T]. The same code with, say, Unit does not crash in the same way.
Pasting the same code into the REPL directly (minus the package declaration) also runs fine.
Removing the package declaration from the file then running Main.main also prevents the problem from occurring.
The text was updated successfully, but these errors were encountered:
The pickled tree of '{None} contains testthething inside the call of an Inlined node. Is that particular case we are probably missing testthething.Main in the classpath. This may be related to #6007.
This error is a little weird to reproduce. First, make a file like this:
If you compile this file using
dotc
then run it usingdotr -with-compiler testthething.Main
everything is fine. If however you open a REPL usingdotr -with-compiler
then try to call the same method explicitly as intestthething.Main.main(Array())
it crashes spectacularly:This seems related somehow to the
T
inOption[T]
. The same code with, say,Unit
does not crash in the same way.Pasting the same code into the REPL directly (minus the package declaration) also runs fine.
Removing the package declaration from the file then running
Main.main
also prevents the problem from occurring.The text was updated successfully, but these errors were encountered: