1
我的iOS应用程序崩溃,并显示以下错误消息。基本上,我试图访问不存在的数组索引。如何知道哪个NSArray导致异常
我该如何让Xcode向我展示确实的数组名称,我在其上做了错误的操作(或导致崩溃的调用堆栈)?
****错误消息我看到***
2015-11-05 09:24:38.509 firstCDapp[1165:734714] *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArray0 objectAtIndex:]: index 0 beyond bounds for empty NSArray' *** First throw call stack: (0x279c585b 0x39086dff 0x27958bdf 0x923f9 0x2be38d63 0x2be38e89 0x2be28df5 0x2be3d46f 0x2bbe35af 0x2baf5cc3 0x2b3bdb05 0x2b3b9201 0x2b3b9091 0x2b3b85b1 0x2b3b8263 0x2b3b1a1f 0x27988091 0x27986387 0x279867c5 0x278d90d9 0x278d8ecd 0x30c4eaf9 0x2bb622dd 0x93b35 0x397d4873) libc++abi.dylib: terminating with uncaught exception of type NSException
请参阅http://www.raywenderlich.com/10209/my-app-crashed-now-what-part-1 – rmaddy
谢谢,该链接非常适合解释如何查找崩溃的来源。 –