[clang] [clang][modulemap] Lazily load module maps by header name (PR #181916)
Michael Spencer via cfe-commits
cfe-commits at lists.llvm.org
Wed Feb 18 16:05:15 PST 2026
================
@@ -1858,7 +2020,7 @@ HeaderSearch::parseAndLoadModuleMapFileImpl(FileEntryRef File, bool IsSystem,
// Try to load a corresponding private module map.
if (OptionalFileEntryRef PMMFile =
- getPrivateModuleMap(File, FileMgr, Diags, !ParsedModuleMaps[File])) {
+ getPrivateModuleMap(File, FileMgr, Diags, false)) {
----------------
Bigcheese wrote:
This diagnosis now happens in `parse{AndLoad}ModuleMapFile` to populate `MMState.PrivateModuleMapFile`, without this change we end up diagnosing it twice. This code changed around a lot, so it may be better to look for a way to make sure it just gets called once.
https://github.com/llvm/llvm-project/pull/181916
More information about the cfe-commits
mailing list