[all-commits] [llvm/llvm-project] cc5412: Add option to exclude headers from clang-tidy anal...
Justin Cady via All-commits
all-commits at lists.llvm.org
Tue May 14 05:48:26 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: cc54129b983799e1aaea77aa0ff3040dc30cbc8c
https://github.com/llvm/llvm-project/commit/cc54129b983799e1aaea77aa0ff3040dc30cbc8c
Author: Justin Cady <desk at justincady.com>
Date: 2024-05-14 (Tue, 14 May 2024)
Changed paths:
M clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.cpp
M clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h
M clang-tools-extra/clang-tidy/ClangTidyOptions.cpp
M clang-tools-extra/clang-tidy/ClangTidyOptions.h
M clang-tools-extra/clang-tidy/tool/ClangTidyMain.cpp
M clang-tools-extra/clang-tidy/tool/run-clang-tidy.py
M clang-tools-extra/docs/ReleaseNotes.rst
M clang-tools-extra/docs/clang-tidy/index.rst
M clang-tools-extra/test/clang-tidy/infrastructure/Inputs/config-files/.clang-tidy
M clang-tools-extra/test/clang-tidy/infrastructure/Inputs/config-files/1/.clang-tidy
M clang-tools-extra/test/clang-tidy/infrastructure/Inputs/config-files/3/.clang-tidy
M clang-tools-extra/test/clang-tidy/infrastructure/config-files.cpp
M clang-tools-extra/test/clang-tidy/infrastructure/file-filter.cpp
Log Message:
-----------
Add option to exclude headers from clang-tidy analysis (#91400)
This is a renewed attempt to land @toddlipcon's D34654. The comments on
that patch indicate a broad desire for some ability to ignore headers.
After considering various options, including migrating to std::regex, I
believe this is the best path forward. It's intuitive to have separate
regexes for including headers versus excluding them, and this approach
has the added benefit of being completely opt-in. No existing configs
will break, regardless of existing HeaderFilterRegex values.
This functionality is useful for improving performance when analyzing a
targeted subset of code, as well as in cases where some collection of
headers cannot be modified (third party source, for example).
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list