Only one precompiled header can be used in a particular compilation. This condition implies that a source file which includes multiple header files will only benefit from the precompiled support for exactly one of those headers. The workaround for this is to create a monolithic header file which includes all other header files, and use only this header file from within the source.
This sort of breaks the simple rule that "include files should never include include files", found IMHO for good reasons in many style guides.
Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds