IntelliJ Idea编译报错:
- Information:Using javac 1.7.0_79 to compile java sources
- Information:java: javacTask: 源发行版 1.7 需要目标发行版 1.7
- Information:java: Errors occurred while compiling module 'xxx'
- Information:15/8/14 下午11:08 - Compilation completed with 1 error and 0 warnings in 1s 913ms
- Error:java: Compilation failed: internal java compiler error
参考了附录中的文章,作如下修改(Idea版本14.1.4):
File-->Other Settings-->Default Settings-->Compiler-->Java Compiler
在Per-module bytecode version下点击“+”,出现的Choose Module框中是空白,无法修改Target bytecode version.
选择项目,右击选择“Open Project Settings”-->Modules-->Language Level,改成6、7、Project Default都不起作用,折腾半天。
在Stackoverflow上偶然搜索到如下说明(http://stackoverflow.com/questions/12900373/idea-javac-source-release-1-7-requires-target-release-1-7):
- I've hit this after just minor upgrade from IntelliJ IDEA 14 to v14.1. For me changing an edit of top/parent pom helped and then clicked re-import Maven (if it is not automatic).
-
- But it maybe just enough to Right Click on module(s)/aggregated/parent module and Maven -> Reimport.
选中项目,右击选择Maven-->Reimport, 再次编译,问题解决。
-------------------------附录------------------------
http://loftor.com/archives/idea-javacTask.html
在idea中编译时发生如下的错误
Information:Using javac 1.7.0_75 to compile java sources
Information:java: javacTask:源发行版1.6需要目标发行版1.6Information:java:Errors occurred while compiling module'kulong'Information:15/3/2613:22-Compilation completed with1 error and0 warnings in5s771msError:java:Compilation failed:internal java compiler error
解决办法
setting->Compiler->Java Compiler 设置相应Module的target byte code version的合适版本就行来。
分享到:
相关推荐
今天小编就为大家分享一篇关于IntelliJ IDEA报错Error:java: Compilation failed: internal java compiler error的解决办法,小编觉得内容挺不错的,现在分享给大家,具有很好的参考价值,需要的朋友一起跟随小编来...
将 FileMon 、FileDisk 等功能集中在一起并虚拟出一个 Windows 的文件系统,该版本使用了MFC的框架! 很早时候自己做的东西,没太多技术含量,整合了一下几个东西,算是个入门例子吧!
fatal error: zmq.hpp: No such file or directory compilation terminated. 找不到zmq.hpp的原因是, zmq.hpp只存在master中。 如果你使用release版本,那么是没有zmq.hpp这个文件的。去master中找到zmq.hpp。 将...
文章目录问题排错与解决Step1、修改当前项目jdk版本Step2、配置并指定maven-compiler-plugin的jdk版本 问题 在idea运行项目的测试类的时候,报标题中的两个错误: 排错与解决 Step1、修改当前项目jdk版本 网上搜了...
Lombok模块jdk10 要重现: ./gradlew -Dorg.gradle.java.home=<path> build 我收到的错误是: > Task :compileJava FAILED /Users/bflint/IdeaProjects/lombok-module-jdk10/src/main/java...> Compilation failed;
解决caffe在make时出现如下错误: src/caffe/util/io.cpp:17:10: fatal ...Makefile:610: recipe for target '.build_release/src/caffe/util/io.o' failed make: *** [.build_release/src/caffe/util/io.o] Error 1
Gradle脚本在Android中的使用
XP系统在回放LoadRunner11录制脚本时提示“Vuser failed to initialize extension LrXml.dll”的解决方法
支持arm与linux的交叉编译编译器。可以在linux台编译arm
src/caffe/util/io.cpp:17:10: fatal error: turbojpeg.h: No such file or...Makefile:624: recipe for target '.build_release/src/caffe/util/io.o' failed make: *** [.build_release/src/caffe/util/io.o] Error 1
这是一个数值软件包,很实用,希望对于做数值计算的朋友有所帮助。
java.lang.Error: Unresolved compilation problem: The method setAttribute(String, Object) in the type ServletRequest is not applicable for the arguments (String, double) y2ssh.sg.chp1.action....
compilation terminated. Makefile:5559: recipe for target '.obj/release-shared/botan.o' failed make[3]: *** [.obj/release-shared/botan.o] Error 1 make[3]: Leaving directory '/opt/qt-creator-open...
Explore various underlying compiler improvements, such as tiered attribution and Ahead-of-Time (AOT) compilation Learn security manager improvements Understand enhancements in graphics rasterizers Use...
软件测试的一些举出内容,对于初次学习这方面的人会有帮助!
Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project
2、Modern.Compiler.Implementation.in.Java.Second.Edition.chm Last year you may have seen the Modern Compiler Implementation in C: Basic Techniques (1997) which was the preliminary edition of our new ...
伯克利:A Java Reference Paul N. Hilfinger University of California, Berkeley 1 Java Overview 9 1.1 Basic Program Structure . . . . . . . . . . . . . . . . . . . . . . . . . 9 1.2 Compilation and ...
Pub Date: 2018 Learn how Java principles ...Explore JIT compilation and Java language performance techniques Learn performance aspects of the Java Collections API and get an overview of Java concurrency