[libcxx-commits] [libcxx] [libc++] run clang-tidy on src/ in the CI (PR #121198)
Nikolas Klauser via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Dec 27 08:12:37 PST 2024
https://github.com/philnik777 updated https://github.com/llvm/llvm-project/pull/121198
>From cb62d54e48bcf19cf69a6517209e7873b2f0e480 Mon Sep 17 00:00:00 2001
From: Nikolas Klauser <nikolasklauser at berlin.de>
Date: Fri, 27 Dec 2024 11:05:25 +0100
Subject: [PATCH] [libc++] run clang-tidy on src/ in the CI
---
libcxx/src/.clang-tidy | 17 ++++++++++++++++-
libcxx/utils/ci/run-buildbot | 2 ++
2 files changed, 18 insertions(+), 1 deletion(-)
diff --git a/libcxx/src/.clang-tidy b/libcxx/src/.clang-tidy
index ec8f2e0a76a3c4..dfbc49fa9d069c 100644
--- a/libcxx/src/.clang-tidy
+++ b/libcxx/src/.clang-tidy
@@ -1,4 +1,19 @@
InheritParentConfig: true
Checks: >
- -readability-identifier-naming
+ -clang-analyzer-*,
+
+ -llvm-include-order,
+
+ -modernize-loop-convert,
+ -modernize-use-equals-delete,
+ -modernize-use-nullptr,
+ -modernize-use-override,
+
+ -readability-identifier-naming,
+ -readability-function-cognitive-complexity,
+ -readability-function-size,
+ -readability-simplify-boolean-expr,
+
+# TODO: Consider enabling clang-analyzer. Without the checks clang-tidy runs 18x
+# faster on my system.
diff --git a/libcxx/utils/ci/run-buildbot b/libcxx/utils/ci/run-buildbot
index f1ede6474eb9ee..0b7a89b5439d54 100755
--- a/libcxx/utils/ci/run-buildbot
+++ b/libcxx/utils/ci/run-buildbot
@@ -328,6 +328,8 @@ generic-cxx26)
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx26.cmake"
check-runtimes
check-abi-list
+ python3 $MONOREPO_ROOT/clang-tools-extra/clang-tidy/tool/run-clang-tidy.py \
+ -clang-tidy-binary clang-tidy-20 -warnings-as-errors \* -source-filter ".*libcxx/src.*" -p "${BUILD_DIR}"
;;
#
# Other compiler support
More information about the libcxx-commits
mailing list