IntelliJ Cannot find declaration to goto----解决方案
方法1、如果jdk的类,都提示Cannot find declaration to goto,那么采用如下方式即可解决:
系统中已经有了该类库,还是找不到类提示
- close the project in intellij.
- close intellij.
- go to the project folder and delete the
.ideafolder - restart intellij and open the project (wait for the indexing to finish) and it would work.
原文地址在这里:https://www.cnblogs.com/sapoo/p/12988726.html
方法2、如果引自其他类库的,则不能用上述方式解决,还在寻找解决方案。
方法1没有起作用。
导入项目的时候使用的是Open而不是Import Project。
原文地址在这里:https://blog.csdn.net/qq_29230875/article/details/106769650

浙公网安备 33010602011771号