================
@@ -3230,10 +3225,13 @@ ASTReader::getModuleForRelocationChecks(ModuleFile &F,
bool DirectoryCheck) {
// session.
auto [EnablesBSValidation, WasValidated] =
wasValidatedInBuildSession(F, HSOpts);
- if (WasValidated)
- return {std::nullopt, IgnoreError};
- if (EnablesBSValidation &&
- static_cast<uint64_t>(F.ModTime) >= HSOpts.BuildSessionTimestamp)
+ const bool SkipModuleLookup =
+ !PP.getPreprocessorOpts().ModulesForceRedundantLookup &&
+ (WasValidated ||
+ (EnablesBSValidation &&
+ static_cast<uint64_t>(F.ModTime) >= HSOpts.BuildSessionTimestamp));
----------------
vsapsai wrote:
Unrelated: I would expect this check to happen in `wasValidatedInBuildSession`
based on the naming. But that's not the point of your change, so it's not
blocking, merely a drive-by comment.
https://github.com/llvm/llvm-project/pull/219107
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits