scala-debug-adapter
scala-debug-adapter copied to clipboard
Failed evaluation of encoded outer
With EvaluationMode.ScalaEvaluationOnly, this test fails:
test("encoded outer") {
val source =
"""|package example
|
|class `A+B` {
| val foo = 42
| object && {
| def x = {
| println(foo)
| 42
| }
| }
|}
|
|object Main {
| def main(args: Array[String]): Unit = {
| val ab = new `A+B`
| println(ab.&&.x)
| }
|}
|""".stripMargin
implicit val debuggee: TestingDebuggee = TestingDebuggee.mainClass(source, "example.Main", scalaVersion)
check(Breakpoint(8), Evaluation.success("foo", 42))
The error message is:
Expected success, got LeftProjection(Left(Cannot evaluate because of failed compilation:
[error] Bad symbolic reference. A signature
[error] refers to Expressionedd69075124f47788efe591c487a9522/T in package example which is not available.
...