Java: Unresolved compilation problem

前端 未结 8 2273
感动是毒
感动是毒 2020-11-22 03:29

What are the possible causes of a \"java.lang.Error: Unresolved compilation problem\"?

Additional information:

I have seen this after copying a set of updat

相关标签:
8条回答
  • 2020-11-22 04:26

    Your compiled classes may need to be recompiled from the source with the new jars.

    Try running "mvn clean" and then rebuild

    0 讨论(0)
  • 2020-11-22 04:30

    (rewritten 2015-07-28)

    The default behavior of Eclipse when compiling code with errors in it, is to generate byte code throwing the exception you see, allowing the program to be run. This is possible as Eclipse uses its own built-in compiler, instead of javac from the JDK which Apache Maven uses, and which fails the compilation completely for errors. If you use Eclipse on a Maven project which you are also working with using the command line mvn command, this may happen.

    The cure is to fix the errors and recompile, before running again.

    The setting is marked with a red box in this screendump:

    0 讨论(0)
提交回复
热议问题