Monday, 14 March 2016

Scala compiler issues in IntelliJ

1. scalac object scala.runtime in compiler mirror not found
scala.reflect.internal.MissingRequirementError: object scala.runtime in compiler mirror not found.

Solution:
In IntelliJ IDE,
File -> Settings -> Build,Execution,Deployment -> Scala Compiler -> select sub project -> Additional Compiler options: remove dependecyFile


2. Error:scalac: Error: assertion failed: List(object package$DebugNode, object package$DebugNode)
      java.lang.AssertionError: assertion failed: List(object package$DebugNode, object package$DebugNode)
       at scala
.reflect.internal.Symbols$Symbol.suchThat(Symbols.scala:1678)
       at scala
.reflect.internal.Symbols$ClassSymbol.companionModule0(Symbols.scala:2988)
       at scala
.reflect.internal.Symbols$ClassSymbol.companionModule(Symbols.scala:2991)
       at scala
.tools.nsc.backend.jvm.GenASM$JPlainBuilder.genClass(GenASM.scala:1371)


Solution: mvn clean compile, then rebuild.

Reference:

No comments:

Post a Comment