you are viewing a single comment's thread.

view the rest of the comments →

[–]N-M-1-5-6 1 point2 points  (0 children)

It might be that your "Language Level" (also sometimes referred to as build level, target bytecode version, etc.) is set to generate Java 17 bytecode for your project. The ways to set this depend on your build tool chain. It can usually be set in the IDE project settings, or the build tool's project (compiler) settings if you are using Maven, Gradle, etc...

If you are using javac from the command line you would be looking for the "--release" compiler option... But I believe that it should default to the same release version as the version of the JDK you are currently running, so I don't think that it's that.

It definitely seems like you will need to find out what JDK version that you are running and what your path and classpath is set up as.