我创建了一个Xamarin Forms应用程序。我在Android上使用multidex(许多库)。 我使用multidex.keep文件并选择MultiDexMainDexList选项。现在部署正常运作。但是在调试模式下我遇到了异常:
System.ArgumentException: The offset and length have exceeded the bounds of the array or the counter value exceeds the number of elements from the pointer to the end of the original collection.
в System.Buffer.BlockCopy(Array src, Int32 srcOffset, Array dst, Int32 dstOffset, Int32 count)
в Mono.Cecil.Metadata.GuidHeap.Read(UInt32 index)
в Mono.Cecil.MetadataReader.InitializeCustomDebugInformations()
в Mono.Cecil.MetadataReader.GetCustomDebugInformation(ICustomDebugInformationProvider provider)
в Mono.Cecil.Cil.PortablePdbReader.Read(MethodDefinition method)
в Mono.Cecil.Cil.CodeReader.ReadMethodBody()
в Mono.Cecil.Cil.CodeReader.ReadMethodBody(MethodDefinition method)
в Mono.Cecil.MethodDefinition.<>c.<get_Body>b__41_0(MethodDefinition method, MetadataReader reader)
в Mono.Cecil.ModuleDefinition.Read[TItem,TRet](TRet& variable, TItem item, Func`3 read)
в Mono.Cecil.MethodDefinition.get_Body()
Mono.Cecil.MethodDefinition.get_DebugInformation()
в Mono.Debugging.Soft.SoftDebuggerSession.LoadPdbType(TypeDefinition type, Dictionary`2 fileToSourceFileInfos)
в Mono.Debugging.Soft.SoftDebuggerSession.LoadPdbFile(String assemblyFileName, String pdbFileName)
в Mono.Debugging.Soft.SoftDebuggerSession.LoadDebugFile(String assemblyFileName, String debugFileName, Func`3 loadDebugFile)
в Mono.Debugging.Soft.SoftDebuggerSession.CheckBetterMatch(TypeMirror type, String file, Int32 line, Int32 column, Location found)
в Mono.Debugging.Soft.SoftDebuggerSession.FindLocationByMethod(MethodMirror method, String file, Int32 line, Int32 column, Boolean& insideTypeRange)
в Mono.Debugging.Soft.SoftDebuggerSession.FindLocationByType(TypeMirror type, String file, Int32 line, Int32 column, Boolean& genericMethod, Boolean& insideTypeRange)
в Mono.Debugging.Soft.SoftDebuggerSession.ResolveBreakpoints(TypeMirror type)
в Mono.Debugging.Soft.SoftDebuggerSession.HandleTypeLoadEvents(TypeLoadEvent[] events)
в Mono.Debugging.Soft.SoftDebuggerSession.HandleEventSet(EventSet es)
в Mono.Debugging.Soft.SoftDebuggerSession.EventHandler()
我使用dex2jar和Java Decompiler进行分析(参考这篇文章)。但现在我不知道该寻找什么问题。
有任何想法吗?