我做了一个小的重构,一切在语法上仍然是正确的,它应该可以肯定地编译。但是,我收到一个错误:
[error] bad symbolic reference. A signature in MyClass123.class refers to type MyClass456
[error] in package com.mypackage which is not available.
[error] It may be completely missing from the current classpath, or the version on
[error] the classpath might be incompatible with the version used when compiling MyClass123.class.
[error] one error found
我没有改变其他任何东西。我什至将代码恢复到以前的未重构版本,但错误仍然存在。我也尝试重新加载 sbt。
也许我需要以某种方式从 sbt 生成的文件中清理项目?如果没有,我该怎么办?