您的位置:首页 > 产品设计 > UI/UE

cannot initialize a parameter of type 'IPCameraNightMode' with an rvalue of type 'int'

2016-12-17 18:09 986 查看
在.mm文件中设置一个枚举变量时,XCode 报了下面错误:

Cannot initialize a parameter of type 'IPCameraNightMode' with an rvalue of type ''int"

上starckoverflow看了一下,原来是在引用枚举值的时候前面需要做一个类型强行转换。

[self setNModeBtns:nightModeInter_old];-》

[self
setNModeBtns:(IPCameraNightMode)nightModeInter_old];
http://stackoverflow.com/questions/8502555/cannot-initialize-a-parameter-of-type-uiremote-notificationtype-with-an-rvalue-o href="http://stackoverflow.com/questions/8502555/cannot-initialize-a-parameter-of-type-uiremote-notificationtype-with-an-rvalue-o" target=_blank>点击打开链接
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐