[libcxx-commits] [libcxx] [libc++] Add missing %{flags} substitution to clang-tidy (PR #171689)
Louis Dionne via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Dec 10 12:13:39 PST 2025
https://github.com/ldionne created https://github.com/llvm/llvm-project/pull/171689
Flags that should be used both for compiling and for linking are provided through the %{flags} substitution. Our clang-tidy tests should be using them, not only %{compile_flags}.
>From 4be1d3ced8aabdaf381a0b7acd791eafa082c8af Mon Sep 17 00:00:00 2001
From: Louis Dionne <ldionne.2 at gmail.com>
Date: Wed, 10 Dec 2025 15:12:26 -0500
Subject: [PATCH] [libc++] Add missing %{flags} substitution to clang-tidy
Flags that should be used both for compiling and for linking
are provided through the %{flags} substitution. Our clang-tidy
tests should be using them, not only %{compile_flags}.
---
libcxx/test/libcxx/clang_tidy.gen.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libcxx/test/libcxx/clang_tidy.gen.py b/libcxx/test/libcxx/clang_tidy.gen.py
index 16c90c3ef7130..b46cc72c08dfd 100644
--- a/libcxx/test/libcxx/clang_tidy.gen.py
+++ b/libcxx/test/libcxx/clang_tidy.gen.py
@@ -27,7 +27,7 @@
{lit_header_undeprecations.get(header, '')}
// TODO: run clang-tidy with modules enabled once they are supported
-// RUN: %{{clang-tidy}} %s --warnings-as-errors=* -header-filter=.* --config-file=%{{libcxx-dir}}/.clang-tidy --load=%{{test-tools-dir}}/clang_tidy_checks/libcxx-tidy.plugin -- -Wweak-vtables %{{compile_flags}} -fno-modules
+// RUN: %{{clang-tidy}} %s --warnings-as-errors=* -header-filter=.* --config-file=%{{libcxx-dir}}/.clang-tidy --load=%{{test-tools-dir}}/clang_tidy_checks/libcxx-tidy.plugin -- -Wweak-vtables %{{flags}} %{{compile_flags}} -fno-modules
#include <{header}>
""")
More information about the libcxx-commits
mailing list