[Qt-creator] autocompletion and pre-compiled headers?

Tyler Daniel tyler at rosette-research.com
Wed Jul 16 03:39:44 CEST 2014


Hi all,

I posted this on the Tools forum, where it was suggested that I also ask here, so here goes!


I’ve been using Creator for quite a while now and I’m determined to fix the most annoying of issues — missing/erratic autocompletion when using precompiled headers.

This has been an issue forever, but currently I’m using 3.1.1 from the 5.3 distribution on a Mac (same problem on Windows 7). My .pro file contains “PRECOMPILED_HEADER = <file>” and then “CONFIG += precompiled_header”. It builds fine. I’ve tried switching to the new clang code model, with little effect.

clang code model: wavy red underlines indicating what would be errors if there were no PCH. no completion.
builtin code model: no red underlines (error indications), but also no completion.

I’m also not clear on how to force a rebuild of the information generated by the code model. I’ve tried cleaning, rebuilding, running qmake, closing and re-opening the project/session/creator itself.

In my adventures I have gotten the following message frequently:
“updatePchInfo: switching to none”

All of this is on a Mac running 10.8.5.

That’s about it. No idea.

Does completion from PCHs work for anyone?

Thanks,
Tyler


More information about the Qt-creator mailing list