[clang] Insert headers in global module fragment (PR #151624)

Mythreya Kuricheti via cfe-commits cfe-commits at lists.llvm.org
Sat Aug 2 22:36:27 PDT 2025


================
@@ -115,6 +134,7 @@ unsigned getOffsetAfterHeaderGuardsAndComments(StringRef FileName,
               return SM.getFileOffset(Tok.getLocation());
             return 0;
           }));
+  return std::max(HeaderAndPPOffset, ModuleDecl);
----------------
MythreyaK wrote:

This does read better, yeah. Will push after current CI run to prevent a restart.

https://github.com/llvm/llvm-project/pull/151624


More information about the cfe-commits mailing list