[clang-tools-extra] [clang-tidy] add misc-constexpr check (PR #146553)

via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 1 08:48:37 PDT 2025


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff HEAD~1 HEAD --extensions h,cpp -- clang-tools-extra/clang-tidy/misc/ConstexprCheck.cpp clang-tools-extra/clang-tidy/misc/ConstexprCheck.h clang-tools-extra/test/clang-tidy/checkers/misc/constexpr-cxx20.cpp clang-tools-extra/test/clang-tidy/checkers/misc/constexpr-ref.cpp clang-tools-extra/test/clang-tidy/checkers/misc/constexpr.cpp clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp b/clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp
index ad00cc50f..c671b28d4 100644
--- a/clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp
+++ b/clang-tools-extra/clang-tidy/misc/MiscTidyModule.cpp
@@ -44,8 +44,7 @@ public:
         "misc-confusable-identifiers");
     CheckFactories.registerCheck<ConstCorrectnessCheck>(
         "misc-const-correctness");
-    CheckFactories.registerCheck<ConstexprCheck>(
-        "misc-constexpr");
+    CheckFactories.registerCheck<ConstexprCheck>("misc-constexpr");
     CheckFactories.registerCheck<CoroutineHostileRAIICheck>(
         "misc-coroutine-hostile-raii");
     CheckFactories.registerCheck<DefinitionsInHeadersCheck>(

``````````

</details>


https://github.com/llvm/llvm-project/pull/146553


More information about the cfe-commits mailing list