我对Scala编程非常陌生。我从GIT中提取了一个代码到IntelliJ中。但是,我在编译时得到了下面的错误。我已经在我的mac上安装了最新的Scala版本(3.2.0) (JDK18也安装了)。
scalac: Error: assertion failed:
No RuntimeVisibleAnnotations in classfile with ScalaSignature attribute: class DefaultFormats
while compiling: /Users/usr/mainProg.scala
during phase: globalPhase=typer, enteringPhase=namer
library version: version 2.13.9
compiler version: version 2.13.9
reconstructed args: -classpath <Several Jar file locations>
last tree to typer: Ident(net)
tree position: line 3 of /Users/usr/mainProg.scala
tree tpe: net.type
symbol: final package net
symbol definition: final package net (a ModuleSymbol)
symbol package: <none>
symbol owners: package net
call site: package processing in package delta in package delta请让我知道我在这里错过了什么。
发布于 2022-10-06 15:50:16
https://docs.scala-lang.org/overviews/jdk-compatibility/overview.html
(虽然它是JDK 18推荐的最低版本,所以3.2.0应该可以使用,请报告跟踪器上的Scala 3 bug)。
https://stackoverflow.com/questions/73975781
复制相似问题