[clang-tools-extra] f0dc266 - [NFC] [clangd] [C++20] [Modules] Improve logging message
Chuanqi Xu via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 27 19:59:30 PDT 2025
Author: Chuanqi Xu
Date: 2025-08-28T10:55:37+08:00
New Revision: f0dc2660997e9dc1dfb017951a1124c5db2e4c23
URL: https://github.com/llvm/llvm-project/commit/f0dc2660997e9dc1dfb017951a1124c5db2e4c23
DIFF: https://github.com/llvm/llvm-project/commit/f0dc2660997e9dc1dfb017951a1124c5db2e4c23.diff
LOG: [NFC] [clangd] [C++20] [Modules] Improve logging message
Improve logging message to help users to debug the failure reasons.
Added:
Modified:
clang-tools-extra/clangd/ModulesBuilder.cpp
Removed:
################################################################################
diff --git a/clang-tools-extra/clangd/ModulesBuilder.cpp b/clang-tools-extra/clangd/ModulesBuilder.cpp
index 23afc9fce556f..64f22b9fdf743 100644
--- a/clang-tools-extra/clangd/ModulesBuilder.cpp
+++ b/clang-tools-extra/clangd/ModulesBuilder.cpp
@@ -333,7 +333,10 @@ buildModuleFile(llvm::StringRef ModuleName, PathRef ModuleUnitFileName,
return llvm::createStringError(
llvm::formatv("Failed to compile {0}. Use '--log=verbose' to view "
- "detailed failure reasons.",
+ "detailed failure reasons. It is helpful to use "
+ "'--debug-modules-builder' flag to keep the clangd's "
+ "built module files to reproduce the failure for "
+ "debugging. Remember to remove them after debugging.",
ModuleUnitFileName));
}
More information about the cfe-commits
mailing list