未找到方法(返回类型默认为“id”)
有谁知道这个 LLVM 警告是什么意思:
Method '-retry' not found (return type defaults to 'id') in sourceFile.m
我在 sourceFile.m 的以下行中收到此警告:
[self.operation retry];
我的类有一个变量“操作”,它是扩展 NSOperation 的自定义类。
MyCustomOperation* operation;
@property (nonatomic, retain) MyCustomOperation* operation;
我的自定义操作类有一个方法:
- (void) retry;
一切似乎都有效,但我确实很想摆脱我的警告。
谢谢!
Does anyone know what this LLVM warning means:
Method '-retry' not found (return type defaults to 'id') in sourceFile.m
I get this warning on the following line of sourceFile.m:
[self.operation retry];
My class has a variable 'operation', which is a custom class extending NSOperation.
MyCustomOperation* operation;
@property (nonatomic, retain) MyCustomOperation* operation;
My custom operation class has a method:
- (void) retry;
Everything seems to work, but I'd sure love to get rid of my warnings.
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
接口中是否也有方法声明
- (void) retry;
,而不仅仅是实现?Do you have the method declaration
- (void) retry;
in the interface too, not just the implementation?您应该检查是否已导入
MyCustomOperation.h
。You should check if you've imported
MyCustomOperation.h
.