Copy from other people there myeclipse Java engineering, open a look marked red a large, careful look, it is not recognized enum keyword, this is a bit embarrassing.
I built a Java project myself and tested it, if I chose JavaSE-1.6 when I was building a new project:
is to identify the enum keyword, but if I choose the second or default jdk1.8, then I find that the Java compiler compliance The maximum limit in level is only 1.7, so the two solutions (the principle is the same), one is to compiler compliance Level is set to more than 1.5, and the other is to change the Org.eclipse.jdt.core under. Settings to the following:
Eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlinejsrbytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetplatform=1.6
org.eclipse.jdt.core.compiler.codegen.unusedLocal =preserve
org.eclipse.jdt.core.compiler.compliance=1.6
org.eclipse.jdt.core.compiler.debug.linenumber= Generate
org.eclipse.jdt.core.compiler.debug.localvariable=generate
Org.eclipse.jdt.core.compiler.debug.sourcefile=generate
Org.eclipse.jdt.core.compiler.problem.assertidentifier=error
Org.eclipse.jdt.core.compiler.problem.enumidentifier=error
org.eclipse.jdt.core.compiler.source=1.6
The above is a small series to introduce the Java enum keyword Unrecognized quick solution, I hope to help you, if you have any questions please give me a message, small series will promptly reply to everyone. Here also thank you very much for the cloud Habitat Community website support!