Code completion doesn't work within #if and #endif
Environment: latest Xcode version: 4.6.2
#if defined(LITE_VERSION)
//code here has no or very limited auto completion
#endif
The target is set to the lite version, so the marcro LITE_VERSION is actually already defined.
I'v already deleted all the derived data manually. (By the way, the delete derived data button is grey in the organizer's window for this particular project)
If I just add a #define LITE_VERSION in the source code, the code completion will work. However, I think it's a dirty fix and error prone.
This issue persists over one year with various Xcode versions, and now I have more and more codes to write for the lite version, I really appreciate a permanent solution.
P.S: While I are writing this question, I also continue the trouble shooting, and finally I found out the solution, So I made this as a self-answered question. Hopefully, it will help others.