unrecognized selector sent to instanceAuto property synthesis will not synthesize property
程序运行崩溃 :'NSInvalidArgumentException', reason: '-[MyAnnotation setCoordinate:]: unrecognized selector sent to instance
产生了一个警告: Auto property synthesis will not synthesize property 'coordinate' declared in protocol 'MKAnnotation'
一般出现unrecognized selector sent to instance这个方法的时候大部分是因为对象被提前释放,指针变成野指针或者没有初始化就调用.这类bug很难定位所以就需要我们定制DEBUG断点
1.在Debug菜单中选择 Breakpoints -> Create Symbolic Breakpoint…
2在Symbol中填写如下方法签名:-[NSObject(NSObject) doesNotRecognizeSelector:]
3.重新运行就可以定位了.
不过也不是百试百灵的.......
我这个错误就不行,那么问题一定是出现在警告的上了--------Auto property synthesis will not synthesize property 'coordinate' declared in protocol 'MKAnnotation'-------
我这个是mapView的模型(必须遵守<MKAnnotation>协议)
定义了一个属性 @property (nonatomic) CLLocationCoordinate2D cooreinate;
就出现了上述警告,Auto property synthesis will not synthesize property这个警告一般都是和系统的命名冲突了,所以就改成@property (nonatomic) CLLocationCoordinate2D coordinate;问题就解决了!
不得不说,就差了一个字母,不懂得人改bug就得一小天啊 ,太坑了
转载于:https://www.cnblogs.com/Jusive/p/5150040.html
unrecognized selector sent to instanceAuto property synthesis will not synthesize property相关推荐
- ios unrecognized selector sent to instance出现的原因和解决方案
概述:造成unrecognized selector sent to instance iphone,大部分情况下是因为对象被提前release了,在你心里不希望他release的情况下,指针还在,对 ...
- unrecognized selector sent to instance
[iOS] Error Fixed : [__NSArrayI addObject:]: unrecognized selector sent to instance 当我创建了一个NSMutable ...
- 小萝莉说Crash(一):Unrecognized selector sent to instance xxxx
写在前面的:分享一篇文,原文地址:小萝莉说Crash(一):Unrecognized selector sent to instance xxxx -------------------------- ...
- 【小萝莉说Crash】第一期:Unrecognized selector sent to instance xxxx
大家好,我是来自Bugly Crash实验室的小萝莉(害羞ing),很高兴能和大家一起讨论关于移动终端App的Crash问题及解决方法. 在上次的"精神哥讲Crash"系列中,精神 ...
- -[AppDelegate window]: unrecognized selector sent to instance
问题 [UIApplication.sharedApplication.delegate.window -] 在Xcode11新建的项目中闪退. 抛出的异常如下: *** Terminating ap ...
- 静态库调用中“unrecognized selector sent to instance”错误
在开发调用静态库的中,出现 "unrecognized selector sent to instance 0x2b5f90"的错误 -[__NSCFConstantString ...
- 错误提示[__NSArrayI addObjectsFromArray:]: unrecognized selector的原因和解决方法
操作NSMutableArray数字增加和删除时候出现崩溃,报错[__NSArrayI addObjectsFromArray:]: unrecognized selector. 找了一个小时,发&q ...
- iOS开发之 [NSNull length]:unrecognized selector sent
2019独角兽企业重金招聘Python工程师标准>>> 错误 [NSNull length]:unrecognized selector sent to instance 这个错误是 ...
- IOS微信API异常:unrecognized selector sent to instance 0x17005c9b0'
2019独角兽企业重金招聘Python工程师标准>>> 开发IOS整合微信API的时候,在运行程序的过程中可能会在注册你的APPID的时候抛出此异常而导致程序崩溃. 异常描述 [76 ...
最新文章
- 理解NSAttributedString
- [英]Promises Don't Come Easy
- c语言实现英文文本编辑器_用flutter实现富文本编辑器(二)
- 实现Datagrid分页
- C语言试题四十一之请编写一个函数,用来删除字符串中的所有空格。
- 【小记】-006--关于高度塌陷的问题
- Cesium多屏展示
- 力扣78. 子集(JavaScript)
- springmvc往html设置变量,SpringMVC:@MatrixVariable矩阵变量
- AC日记——[HNOI2012]永无乡 bzoj 2733
- 《初级会计电算化实用教程(金蝶KIS专业版)》一1.5 课后习题
- 一位技术演讲家的自白
- ubuntu 20 无法联网或无法解析域名(2022最新办法,实测有效)
- 写作分册王诚pdf_后王诚时代|老铁们,管综写作还能跟谁?
- 计算机组老师颁奖词,学生表彰颁奖词与学生计算机室管理制度合集.doc
- 连续时间周期信号傅里叶级数
- 火狐浏览器的全屏兼容问题 allowfullscreen=true
- 目标检测FPN(Feature Pyramid Networks)的使用
- 老子说:知其雄,守其雌
- 收藏能力升级,支付宝版「小程序桌面」初现!
热门文章
- 【Linux】一步一步学Linux——env命令(201)
- 【Tools】Visual Studio 2017下载和安装
- Android源码解析--AlertDialog及AlertDialog.Builder
- mysql工_mysql
- 液晶显示器背光测试软件,液晶灰阶|饱和度|背光测试
- matlab计算斜方差_Matlab求方差,均值,均方差,协方差的函数
- HTTP协议学习笔记(一)请求方法名及状态码
- C++Primer 中文版第5版 习题3.26
- 颜色分类—leetcode75
- string中删除一个元素