因为这个纠结了许久,后来终于在http://forums.macrumors.com/showthread.php?t=895581找到了答案,
Are you sure that "self" is still a valid object once your button is clicked? It could be a memory management bug and you're releasing the object too early.
Can you post more code? |
Hello, sorry for not following up on this thread, I just wanted to let you know how I solved this problem:
Yes I was releasing the class too early, there's a hint in the error:
Code:
[NSCFType generatePieChart]: unrecognized selector sent to instance 0x4d80b00' |
大意就是NSCFType这个东西是没有在文档中提到的内部类,我想给你发送消息的类已经被释放掉了,NSCFType这个东西被存放在他原来的位置上,所以会这样提示