当我点击f5时,我在调试窗口中得到这个文本Error: LinkageError occurred while loading main class Hello java.lang.UnsupportedClassVersionError: Hello (class file version 52.65535) was compiled with preview features that are unsupported. This version of the Java Runtime only recognizes preview features for class file version 56.65535爪哇 -版本显示javac 12爪哇 -版本openjdk version "12" 2019-03-19OpenJDK Runtime Environment AdoptOpenJDK (build 12+33)OpenJDK 64-Bit Server VM AdoptOpenJDK (build 12+33, mixed mode, sharing)我正在尝试编译的代码public class Hello { public static void main(String[] agrs) { System.out.println("Hello world!"); }}正确设置了路径、JAVA_HOME和JRE_HOME。已安装调试加载项。我可以在 InteliJ IDEA 或使用 java(文件),javac(文件)编译和运行相同的代码,它可以正常工作,但我不知道为什么它不适用于 vscode。
添加回答
举报
0/150
提交
取消