从崩溃日志中检测故事板

Detecting storyboard from the crash log

我遇到了以下日志的崩溃:

Storyboard (<UIStoryboard: 0x7ebdd20>) doesn't contain a view controller with identifier 'personDetailVC'

我已经实现了根据某些条件切换故事板并相应地更新故事板名称和视图控制器名称的代码。我所需的情节提要具有情节提要 ID 'personDetailVC'。但我想验证故事板是否正确。有什么方法可以根据日志中的 <UIStoryboard: 0x7ebdd20> 信息跟踪情节提要吗?

你可以尝试用gdb查看UIStoryboard的描述,在日志输出中写入:

po 0x7ebdd20

它类似于 NSLog("%@", yourObject)

po是print object的首字母缩写,是gdb调试器打印对象描述的特殊命令。