I have something like this:
@protocol MyProtocol <NSObject> - (void)oneMethod; @end
.
@interface BaseClassWithProtocol : NSObject <MyProtocol> @end
.
@interface ChildClassWithProtocol : BaseClassWithProtocol @end
BaseClassWithProtocol implemented oneMethod , and I want to show a warning if ChildClassWithProtocol does not call super in its oneMethod implementation.
But I donβt know where to write __attribute__((objc_requires_super)) .
Logging is not supported when overriding oneMethod in .h looks silly.
So, is there a standard way that can solve the problem?
ios objective-c
Tepmnthar
source share