iPhone开发--XCode14升级MLeaksFinder报错

  1. 报错内容
    报错在 FBClassStrongLayout.mm 文件的 layoutCache[currentClass] = ivars; 这一行,
    替换为 layoutCache[(id)currentClass] = ivars; 就好了

  2. 编译正常,但是运行时出现crash

indirect_symbol_bindings[i] = cur->rebinding FBRetainCycleDetector iOS15 fishhook c

手动去 Pods/FBRetainCycleDetector/fishhook/fishhook.c文件中替换内容

indirect_symbol_bindings[i] = cur->rebindings[j].replacement;if (i < (sizeof(indirect_symbol_bindings) / sizeof(indirect_symbol_bindings[0]))) {
    
    
 indirect_symbol_bindings[i]=cur->rebindings[j].replacement;
 }

安装MLeaksFinder的语法为

pod 'MLeaksFinder', :configurations => ['Debug']

参考自:

  • https://juejin.cn/post/6998096709045714951
    https://www.jianshu.com/p/279bbbc87fc9

猜你喜欢

转载自blog.csdn.net/zcl369369/article/details/130828740