ios - iphone项目导入百度地图后出现错误(见详情)
大家讲道理
大家讲道理 2017-04-17 12:59:44
0
1
839

导入百度地图需要下面的操作:

静态库中采用ObjectC++实现,因此需要您保证您工程中至少有一个.mm后缀的源文件(您可以将任意一个.m后缀的文件改名为.mm),或者在工程属性中指定编译方式,即将Xcode的Project -> Edit Active Target -> Build -> GCC4.2 - Language -> Compile Sources As设置为"Objective-C++"

当我设置之后,编译不过,因为在项目中引入mantle这个类库,提示了如下的错误(省略了一些不必要的):

In file included from /Users/YSQ/Desktop/TransunerOA/TransunerOA/Models/WAInfoModel.h:10:
/Users/YSQ/Desktop/TransunerOA/TransunerOA/Vendors/Mantle/MTLJSONAdapter.h:45:69: error: expected identifier
- (NSValueTransformer *)transformerForModelPropertiesOfClass:(Class)class;
                                                                    ^
/Users/YSQ/Desktop/TransunerOA/TransunerOA/Vendors/Mantle/MTLJSONAdapter.h:45:69: error: expected ';' after method prototype
- (NSValueTransformer *)transformerForModelPropertiesOfClass:(Class)class;

Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 1

是否因为该类库引用了class关键字?
该如何修复?

大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(1)
阿神

I also want to know

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!