1

I am cross-posting this from Stack Overflow because the question does not fits better in this stack exchange network.

I am using Xcode 5.1.1 on Mountain Lion and creating a command line application in C++. I have some weird problems with headers and autocomplete. For example, when typing in <vector> I get a suggestion for vector.h which is obviously an invalid file.

enter image description here

Next, autocomplete seems to be missing for several headers including but not limited to unordered_map, random, mutex, tuple.

enter image description here

However, while the autocomplete does not work for these headers, they compile fine and clang seems to know where to find them.

If it helps, these are my search path preferences (these are the default on my system). There is nothing under User or Library search paths and only $inherited and only /Applications/Xcode.app/.../usr/include (as seen in the image) under Header Search Paths. These are the same default paths as found on another machine though.

enter image description here

I checked on that other mac machine and there, everything works as it should. Autocomplete for everything works perfectly and only displays one entry (and the icon shows a c++ file instead of a blank white page).

Does anyone know what could be the problem, or at least where Xcode searches for headers shown in its autocomplete window?

0

Fixed it by updating to mavericks (something I've been meaning to do for a long time). It seems that doing so updates the place where headers are stored.

1
  • well that's a radical solution to solve that problem
    – jokoon
    Jun 6 '15 at 22:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.