------- Comment #5 from sacolcor at provide dot net 2009-05-21 18:21 ------- (In reply to comment #4) > How can the PCH contain information that is lost by using an external > preprocessor?
When I do -save-temps, it's still using the GNU CPP, not an external one, so it's not clear to me why information would be lost. I'll update the summary line so that it's clear that I'm not using an external preprocessor. When a .h.gch is built in one pass, the integrated preprocessor takes the preprocessor symbol state at the end of the file and passes it through (or around) the compile and assemble phases to be stored in the .h.gch file. It seems like the CPP should do the same thing when invoked as part of the -save-temps chain; embed that same information in the .i* files. Then when the compiler phase sees it, it could pass it through and store that information in the .h.gch. Perhaps I need to understand more about how the PCH system works; I looked for that information in the internal doc, but could not find anything. -- sacolcor at provide dot net changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |UNCONFIRMED Resolution|INVALID | Summary|Generated GCH fails to honor|GCH generated with -save- |include guards with -no- |temps does not store |integrated-cpp |preprocessor state. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40215