[java问题记录]IntelliJ Idea编译报错:javacTask: 源发行版 1.8 需要目标发行版 1.8
原因:不详,可能是升级idea造成的,之前打过一个升级补丁;
错误信息:
Information:java: javacTask: 源发行版 1.8 需要目标发行版 1.8
Information:2017/1/24 11:27 - Compilation completed with 1 error and 0 warnings in 5s 873ms
Information:java: Errors occurred while compiling module ‘java-lessions‘
Information:javac 1.8.0_91 was used to compile java sources
Information:Module "java-lessions" was fully rebuilt due to project configuration/dependencies changes
Error:java: Compilation failed: internal java compiler error
尝试的解决方法:
1、修改SDK 版本到1.8,依然无解;
2、修改 languages level 到8,依然是无效;
最终解决方案:
file--> settings--> java complier --- > 找到项目module,修改为1.8 就可以了。
然后运行测试代码,一切OK了~
文章来自:http://www.cnblogs.com/hager/p/6346866.html