我从github 下载了Drupal-iOS-SDK,并且我还下载了AFNetworking文件from here。将drupal-ios-sdk与iPhone应用程序集成的问题
然后,我添加文件到我的项目,但它显示了一个奇怪的错误
Incompatible block pointer types sending 'void (^)(NSInteger, NSInteger, NSInteger)' to parameter of type 'void (^)(NSInteger, long long, long long)'
的这段代码:
AFHTTPRequestOperation *operation = [[AFHTTPRequestOperation alloc] initWithRequest:request];
[operation setUploadProgressBlock:^(NSInteger bytesWritten, NSInteger totalBytesWritten, NSInteger totalBytesExpectedToWrite) {
NSLog(@"Sent %d of %d bytes", totalBytesWritten, totalBytesExpectedToWrite);
}];
有没有人有任何想法,这是什么意思?
我刚尝试过了,现在,它给出了一个类似的错误:不兼容的块指针类型发送“无效(^)(NSInteger的,长长,长长)”来类型的参数“无效(^)( NSInteger,long long long long)' – Shahnawaz
我已经更新了一下我的代码,确保你做了一个干净的构建,并且肯定使用了LLVM编译器为您的项目和目标 –
我清理了我的解决方案并按照你的要求做了,它只会从NSLog中删除警告,但它仍然显示错误。也许你应该去上面的Drupal-iOS-SDK链接并将其集成到一个空白项目中。只是建立它,看看为什么你会得到这样的错误。谢谢! – Shahnawaz