Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
767 views
in Technique[技术] by (71.8m points)

Error in android studio java

please help us.. we cant find whats wrong..

Error:Android Dex: [DDSK] UNEXPECTED TOP-LEVEL EXCEPTION:
Error:Android Dex: [DDSK] at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.processOne(Main.java:672)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.processAllFiles(Main.java:574)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.runMonoDex(Main.java:311)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.run(Main.java:277)
Error:Android Dex: [DDSK] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Error:Android Dex: [DDSK] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
Error:Android Dex: [DDSK] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
Error:Android Dex: [DDSK] at java.lang.reflect.Method.invoke(Method.java:497)
Error:Android Dex: [DDSK] at org.jetbrains.android.compiler.tools.AndroidDxRunner.runDex(AndroidDxRunner.java:161)
Error:Android Dex: [DDSK] at org.jetbrains.android.compiler.tools.AndroidDxRunner.main(AndroidDxRunner.java:294)
Error:Android Dex: [DDSK] at com.intellij.rt.execution.CommandLineWrapper.main(CommandLineWrapper.java:130)
Error:Android Dex: [DDSK] Caused by: com.android.dx.cf.iface.ParseException: InvokeDynamic not supported
Error:Android Dex: [DDSK] at com.android.dx.cf.cst.ConstantPoolParser.determineOffsets(ConstantPoolParser.java:226)
Error:Android Dex: [DDSK] at com.android.dx.cf.cst.ConstantPoolParser.parse(ConstantPoolParser.java:132)
Error:Android Dex: [DDSK] at com.android.dx.cf.cst.ConstantPoolParser.parseIfNecessary(ConstantPoolParser.java:124)
Error:Android Dex: [DDSK] at com.android.dx.cf.cst.ConstantPoolParser.getPool(ConstantPoolParser.java:115)
Error:Android Dex: [DDSK] at com.android.dx.cf.direct.DirectClassFile.parse0(DirectClassFile.java:482)
Error:Android Dex: [DDSK] at com.android.dx.cf.direct.DirectClassFile.parse(DirectClassFile.java:406)
Error:Android Dex: [DDSK] at com.android.dx.cf.direct.DirectClassFile.parseToInterfacesIfNecessary(DirectClassFile.java:388)
Error:Android Dex: [DDSK] at com.android.dx.cf.direct.DirectClassFile.getMagic(DirectClassFile.java:251)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.parseClass(Main.java:764)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.access$1500(Main.java:85)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main$ClassParserTask.call(Main.java:1684)
Error:Android Dex: [DDSK] at com.android.dx.command.dexer.Main.processClass(Main.java:749)
Error:Android Dex: [DDSK] ... 20 more
Error:Android Dex: [DDSK] 1 error; aborting
See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You're compiling some code which uses the invokedynamic instruction, which is not supported on Android. One possible reason is that you've used the Java 8 compiler and used lambdas in your code. Another possibility is that you're trying to use a class which wasn't written in Java, but in some other language such as Groovy.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...