步骤:
1、打开problem透视图看看,有提示是什么错误的
2、如果看见了错误提示:java compiler level does not match the version of the installed java project
3、解决方法:右键项目“Properties”,在弹出的“Properties”窗口左侧,单击“Project Facets”,打开“Project Facets”页面。在页面中的“Java”下拉列表中,选择相应版本就OK了,使得与java compiler(也可以在properties中进行配置)的版本一致。
转载于:https://www.cnblogs.com/LynnLin2016/p/5932583.html