Xcode 4 is not indexing my project

扶醉桌前 提交于 2019-12-23 12:41:14

问题


I have a project where Xcode 4 stopped indexing. As a consequence neither the complete class browser (symbol navigator) nor code sense work. 0 Classes and Protocols etc. are shown. I restarted indexing process by removal of some temporary files in the derived data and the xcodeproj area. But this does not help. Does anyone know what can Xcode prevent from indexing?

I rebuilt the whole project and hopefully found the reason: In my-Prefix.pch file I included #import <myheader.h>, where myheader.h was resolved via Header Search Path. When I changed this line to #import "myheader.h", code sense and class browser worked again.


回答1:


This occurs a few times a week on my mac.

  1. I quit xcode
  2. I delete the ~/Library/Developer/Xcode/DerivedDatas folder
  3. I relaunch Xcode, reindex start again.

Hope this will work for you too.




回答2:


If deleting derivedData didn't work for you just tick the Target Membership box on the right side while your xcode is set to recently imported .m file



来源:https://stackoverflow.com/questions/5887327/xcode-4-is-not-indexing-my-project

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!