Select the project, then File > ProjectStructure > ProjectSettings > Modules -> sources
You probably have the Language Level set at 9:
Just change it to 8 (or whatever you need) and you’re set to go.
Also, check the same Language Level settings mentioned above, under Project Settings > Project
More Related Contents:
- Error: Could not find or load main class in intelliJ IDE
- How to view the list of compile errors in IntelliJ?
- incompatible types required char found java.lang.string
- Auto errors detection in IntelliJ IDEA
- java.lang.ClassNotFoundException when running in IntelliJ IDEA
- Package conflicts with automatic modules in Java 9
- What is the best way to deploy JavaFX application, create JAR and self-contained applications and native installers
- Java “lambda expressions not supported at this language level”
- Trying to read from the console in Java
- How to compile a java source file which is encoded as “UTF-8”?
- How do I set up IntelliJ IDEA for Android applications?
- How to see JavaDoc in IntelliJ IDEA? [duplicate]
- JAVA_HOME should point to a JDK not a JRE
- Best way to add Gradle support to IntelliJ Project
- Java Error: illegal start of expression
- How to convert a normal java project in intellij into a JavaFx project
- Hot swapping in Spring Boot
- Problems importing project into Android Studio regarding ActionBarSherlock
- How can Eclipse create a class with unresolved compilation problems?
- Class file has wrong version 52.0, should be 50.0
- Building with Intellij 2017.2 /out directory duplicates files in /build directory
- Java FX Modular Application, Module not found (Java 11, Intellij)
- Unable to use Intellij with a generated sources folder
- Class Not Found: Empty Test Suite in IntelliJ
- Change remote repository credentials (authentication) on Intellij IDEA 14
- Java 8: Reference to [method] is ambiguous [duplicate]
- Failed to resolve: com.google.android.gms:play-services in IntelliJ Idea with gradle
- What does it mean if a variable has the name “this$0” in IntelliJ IDEA while debugging Java?
- The local variable might not have been initialized – Detect unchecked exception throw within a method
- What does the “Multiple markers” mean?