Xcode版本问题:Unknown argument type ‘__attribute__‘ in method -[RCTAppState getCurrentAppState:error:].
程序员文章站
2022-04-19 15:05:14
遇到的问题:Xcode版本升级后,在Xcode上点击build时遇到以下问题:Unknown argument type '__attribute__' in method -[RCTAppState getCurrentAppState:error:]. Extend RCTConvert to support this type.如图:解决的方法:1.在Xcode中打开:Xcode打开RCTModuleMethod.mm文件:路径Libraries->React.xcodeproj-...
遇到的问题:
Xcode版本升级后,在Xcode上点击build时遇到以下问题:
Unknown argument type '__attribute__' in method -[RCTAppState getCurrentAppState:error:]. Extend RCTConvert to support this type.
如图:
解决的方法:
1.在Xcode中打开:Xcode打开RCTModuleMethod.mm文件:路径Libraries->React.xcodeproj->React->Base ->RCTModuleMethod.mm
2.更改代码:
static BOOL RCTParseUnused(const char **input)
{
return RCTReadString(input, "attribute((unused))") ||
RCTReadString(input, "__attribute__((__unused__))") ||
RCTReadString(input, "__unused");
}
3.clean Xcode :click product->clean or shift+cmd+k
4.重新build,跑的贼溜
本文地址:https://blog.csdn.net/koufulong/article/details/107279920
上一篇: 想着过河拆桥了是吧