lookUpImpOrForward流程图
2021-07-07 17:54:49 0 举报
lookUpImpOrForward流程图
作者其他创作
大纲/内容
是
return imp
return nil
resolveMethod_lockedspan style=\
否
log_and_fill_cache将sel和imp插入消息接收者的类的缓存
imp = forward_imp跳出循环
imp = meth->impgoto done获取imp,调整done流程
lookUpImpOrForward 流程图
此方法不用缓存 span style=\
imp是否存在
(behavior & LOOKUP_NOCACHE) == 0是否需要缓存
imp == forward_imp
imp == NULL
behavior = LOOKUP_INITIALIZE
imp 是否存在
meth 是否存在
cls->isInitialized()类是否初始化
(curClass = curClass->getSuperclass()) == nilcurClass = 父类
报错 Attempt to use unknown class
font color=\"#0097a7\
(behavior & LOOKUP_NIL) && imp == forward_imp
循环
_lookUpImpTryCachespan style=\
imp = cache_getImp共享缓存中查找
meth = getMethodNoSuper_nolockspan style=\
imp = cache_getImpspan style=\
behavior & LOOKUP_RESOLVER是否执行过动态方法决议
!cls->isInitialized()类是否初始化
curClass = curClass->cache.preoptFallbackClass()
lookUpImpOrForward
checkIsKnownClass(cls)类是否注册是否dyld加载的
cls->isRealized()类是否实现
span style=\
0 条评论
下一页