4 ms·
I think you are misusing the PCH feature, in my opinion you are _supposed_ to include the code you depend on in the PCH: STL, QT and the likes and nothing of yo
by lbert 3y ago
I think you are misusing the PCH feature, in my opinion you are _supposed_ to include the code you depend on in the PCH: STL, QT and the likes and nothing of your of the project code, those libraries will almost never change in your project (and you surely want to rebuild everything when that happens) and in most cases they are the slowest to build.
In this case, compilation time of the PCH won't matter much because it will happen very rarely.
After importing all of that stuff regardless of your use of it, include all internal projects normally and using IWYU on those is actually a good idea, as said by rewmie, to reduce bugs.
An other way might be to try to use header units or C++20 modules if you can (afaik QT doesn't support them)