The following error occurred during compiling java code using idea:
Error:java : javacTask: source release 1.7 requires target release 1.7
Above:
When such a problem occurs, you can set it in settings:
Here, set the compiler version to 1.7. One is to set project, two is to set module.
If you build with maven, you can directly specify the compiled version of Java in POM. Add the following code:
<build>
<finalName>5_mybatis_maven</finalName>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
</plugins>
</build>
Then select pom.xml Right click reinport to let Maven download the corresponding plug-ins
Now to compile, is not to see the rain in the rainbow!
Reference link:
http://stackoverflow.com/questions/12900373/idea-javac-source-release-1-7-requires-target-release-1-7
Read More:
- javac Task Error source release 1.7 requires target release
- Java in idea: warning: source release 11 needs to be resolved by target release 11
- Android studio reported an error in the release package: Lint found fatal errors while assembling a release target
- Maven invalid source release 11
- IntelliJ idea error: error: Java does not support release 5
- [Java] error: Java: error: release 13 is not supported
- Idea error: error: Java: error: release 5 is not supported
- Error: Java: error: release version 5 not supported solution to run error
- Using Mocha to test can not find module ‘. /build/release/scrypt’ (Fixed)
- Waiting for another pilot command to release the startup lock
- Execution failed for task :Test:lintVitalRelease/Lint found fatal errors while assembling a release
- Oracle data file space release
- Windows can’t delete the file, indicating that it is in use. (release of document occupation)
- Springboot2.0.4.release report error executing DDL via JDBC statement
- Java: compilation failed: internal java compiler error and invalid source distribution resolution
- ubuntu-how to solve the error-Failed to fetch http://dl.google.com/linux/chrome/deb/dists/stable/Release
- Why interview requires reading the source code
- Error: (44,73) lambda expression and XML are not supported in Java: – source 1.7 Error:java : Compilation failed
- java.lang.VerifyError : inconsistent stackmap frames at branch target
- QuickFIX/J100% Java Open Source FIX Engine