Class_addMethod on iphone (objective-c)

I am trying to use the answer accepted here: Dynamic UIMenuItems with @selector and dynamic methods But it gives a warning (and this does not work): implicit declaration of function 'class_addMethod'

I searched google but have no idea.

+4
source share
1 answer

Add #include <objc/runtime.h> to the top of the implementation file (.m or .c).

+13
source

All Articles