1、File > Settings > Build, Execution, Deployment > Java Compiler
2、Change Target bytecode version to 1.8 of the module that you are working for.
If you are using Maven
Add this to pom.xml under the top-level project node:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
Error:java: javacTask: source release 1.8 requires target release 1.8
猜你喜欢
转载自zyz611.iteye.com/blog/2311810
今日推荐
周排行