0
这是一个例外,并且我无法在IDE中使用这些工具我有一个非常基本的问题。我如何去导致问题的代码行?我找到了问题所在,而不是在didload
和didAppear
事件中记录NSLogging消息,然后遍历代码,直到出现断点,这似乎是解决这个问题的一个很长的路要走。我假设[5970:1623718]是一个线索,但是是什么?由于未被捕获的错误导致的iOS应用程序终止
2017-10-04 08:22:47.798 Auto Mileage - Universal[5970:1623718] *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM objectAtIndex:]: index 4 beyond bounds [0 .. 3]' *** First throw call stack: (0x2580f91b 0x24faae17 0x2572172b 0xd89e3 0xd9e57 0x2a0d1465 0x2a0d15a5 0x2a0c0b51 0x2a0d5d1b 0x29e7523b 0x29d86a73 0x27e1ebcd 0x27e1a375 0x27e1a209 0x27e196d1 0x27e193a5 0x29d7db79 0x257d16c9 0x257cf9cd 0x257cfdff 0x2571f229 0x2571f015 0x26d0fac9 0x29df3189 0xe9159 0x253c7873) libc++abi.dylib: terminating with uncaught exception of type NSException
你应该添加一个[异常断点](https://stackoverflow.com/questions/17802662/exception-breakpoint-in-xcode)。 – the4kman