当“0”时出现Android编译错误;生成类.dex…”;

当“0”时出现Android编译错误;生成类.dex…”;,android,Android,当设置我的机器在Android上工作时,我无法让代码“编译”,或者可能它正在编译并在其他过程中停止,因为当它说“Generating classes.dex”时会出现错误 我得到的错误如下: Information: Note: Some input files use unchecked or unsafe operations. Information: Note: Recompile with -Xlint:unchecked for details. Information: Compi

当设置我的机器在Android上工作时,我无法让代码“编译”,或者可能它正在编译并在其他过程中停止,因为当它说“Generating classes.dex”时会出现错误

我得到的错误如下:

Information: Note: Some input files use unchecked or unsafe operations.
Information: Note: Recompile with -Xlint:unchecked for details.
Information: Compilation completed with 12 errors and 2 warnings
Information: 12 errors
Information: 1 warning
Error: (org.joda.time.DateTimeZone$1) that doesn't come with an
Error: associated EnclosingMethod attribute. This class was probably produced by a
Error: compiler that did not target the modern .class file format. The recommended
Error: solution is to recompile the class from source, using an up-to-date compiler
Error: and without specifying any "-target" type options. The consequence of ignoring
Error: this warning is that reflective operations on this class will incorrectly
Error: indicate that it is *not* an inner class.
Error: (junitx.extensions.TestSetup$1) that doesn't come with an
Error: (junitx.ant.TestClassValidatorTask$1) that doesn't come with an
Error: (junitx.util.AbstractSuiteBuilder$1) that doesn't come with an
Error: (junitx.framework.TestSuite$1) that doesn't come with an
Error: (junitx.tool.TestClassValidator$1) that doesn't come with an
Warning: warning: Ignoring InnerClasses attribute for an anonymous inner class
有趣的是,这段代码可以在另一台计算机上正确编译,这台计算机是很久以前安装的,没有人记得做了什么

我疯狂地在谷歌上搜索,每个人都说你需要从源代码JodaTime和其他任何东西重新编译,但这不可能是真的,因为相同的代码(复制、粘贴或从版本控制下载)在另一台机器上完美地工作,所以一定是我的环境导致了这一点,但我不知道该找什么

有没有认识到这类错误的专家?
你有过这样的经历吗?你是怎么修好的

请帮忙

注:
-使用intellij
-为Android1.6编译


在有人指出之前,我知道以前也有人问过类似的问题。这里举个例子:。但在这种情况下,建议的解决方案是重新编译JodaTime源。我认为情况并非如此,因为代码在一台计算机上运行,而在另一台计算机上运行。

我收到了相同的错误消息,结果是由于包含了两个声明相同类的库(例如,库的旧版本和新版本)。不知道错误消息与此有何关系,但删除旧版本解决了我的问题。

您是否尝试过更新IntelliJ

我根本不是专家,但几天前我遇到了同样的问题,花了很长时间才弄清楚是什么问题。 结果是IntelliJ版本


只需更新到最新版本(夜间构建)即可使其正常工作。

可能与您正在使用的jdk版本有关。你能检查一下你电脑上的jdk版本和它工作的另一个版本吗!!我使用的是10.0.0版,更新到10.0.3版,前者是一个错误,后者只是一个警告,我终于能够编译了。谢谢