If the JDK version is correct in Eclipse but an error occurs or the compiler does not work properly
What to do if an error occurs or the compiler does not work properly even though the JDK version is correct in Eclipse
procedure
- Open Window-> Preferences-> Java-> Compiler
- Change the Compiler compliance level of JDK Compliance to another version once.
- Press Apply and Close
- A confirmation screen will appear. Press Yes and wait for a while until the process is completed.
- Return the Compiler compliance level to the desired version from the screen of 1.
- Follow steps 3 and 4
If the settings are correct on the display but the JDK is not working properly, this operation may help.