在 Scala 2.12.10 中,'scala.tools.nsc' 包已被移除,因此您将无法在该版本中使用它。相反,Scala 2.12.10 引入了新的编译器接口(Compiler Interface),其中包括 'scala.tools.nsc.interpreter' 包和 'scala.tools.nsc.reporters' 包。

如果您需要使用旧的 Scala 编译器 API,则应考虑使用 Scala 2.11.x 版本。但是,最好的选择是尽可能使用新的编译器接口。

Scala 2.12.10 编译器接口变更:scala.tools.nsc 包移除

原文地址: https://www.cveoy.top/t/topic/myvZ 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录