ilya-biryukov added inline comments.
================ Comment at: include/clang/Frontend/ASTUnit.h:581 + unsigned getPreambleCounter() const { return PreambleCounter; } + ---------------- NIT: `getPreambleCounterForTests()`? This is clearly an internal detail, would try giving it a name that discourages using it outside the testing code. ================ Comment at: lib/Frontend/ASTUnit.cpp:1369 // Try again next time. - PreambleRebuildCounter = 1; + ++PreambleCounter; + PreambleRebuildCountdown = 1; ---------------- Why not increase this counter unconditionally for **every** error? (And a non-error case too, I guess) ================ Comment at: lib/Frontend/PrecompiledPreamble.cpp:471 + } else { + auto FilePath = PathNormalized(RB.first.begin(), RB.first.end()); + OverridenFileBuffers[FilePath] = PreambleHash; ---------------- Could we avoid adding path normalization in this patch? Would it break anything? This is clearly an important detail that preamble **might** get wrong, but I'd rather add it in a separate patch to avoid putting multiple things in the same patch. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D41005/new/ https://reviews.llvm.org/D41005 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits