[clang-tools-extra] [clang-tidy] support parameters file in command line (PR #120547)
Congcong Cai via cfe-commits
cfe-commits at lists.llvm.org
Thu Dec 19 15:50:44 PST 2024
================
@@ -553,6 +555,20 @@ static llvm::IntrusiveRefCntPtr<vfs::OverlayFileSystem> createBaseFS() {
int clangTidyMain(int argc, const char **argv) {
llvm::InitLLVM X(argc, argv);
+ SmallVector<const char *> Args{argv, argv + argc};
+
+ llvm::BumpPtrAllocator Alloc;
----------------
HerrCai0907 wrote:
extract to another function is impossible because variable lifetime issue. The allocator must have same lifetime with argc
and argv.
https://github.com/llvm/llvm-project/pull/120547
More information about the cfe-commits
mailing list