void objc_msgSend(void /* id self, SEL op, ....*/)
[self class] <=> objc_msgSend(self. @selector(class))
void objc_msgSendSuper(void /* struct objc_super *super, SEL op, ...*/)
struct objc_super {
__unsafe_unretained id receiver;
}
[super class] <=> objc_msgSendSuper(super, @selector(class))
複製代碼
以SEL爲能夠,經過hash查找具體IMP緩存
一、對於已排序的方法列表,採用二分查找 二、對於未排序的方法列表,採用通常遍歷數據結構
class_addMethod(self, @selector(deletionMethod), addedMethod, "v@:");
複製代碼
@dynamic函數