[clang] [clang][deps] Generate command lines lazily (PR #65691)

Ben Langmuir via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 7 16:09:41 PDT 2023


================
@@ -532,7 +539,8 @@ ModuleDepCollectorPP::handleTopLevelModule(const Module *M) {
   // Finish the compiler invocation. Requires dependencies and the context hash.
   MDC.addOutputPaths(CI, MD);
 
-  MD.BuildArguments = CI.getCC1CommandLine();
+  MD.BuildInvocationOrArguments =
+      std::make_unique<CowCompilerInvocation>(std::move(CI));
----------------
benlangmuir wrote:

You have shared_ptr but call make_unique; it works but seems unexpected

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


More information about the cfe-commits mailing list