[clang-tools-extra] [clang-tidy] Teach `cppcoreguidelines-interfaces-global-init` about `constinit` (PR #148334)
Victor Chernyakin via cfe-commits
cfe-commits at lists.llvm.org
Fri Jul 11 22:57:45 PDT 2025
================
@@ -1,4 +1,4 @@
-// RUN: %check_clang_tidy %s cppcoreguidelines-interfaces-global-init %t
+// RUN: %check_clang_tidy -std=c++20 %s cppcoreguidelines-interfaces-global-init %t
----------------
localspook wrote:
Would you be fine with some `#if __cplusplus >= 202002L` guards instead? The code blocks with `constinit` mirror code blocks without it, so I feel the test reads better when they stay together.
https://github.com/llvm/llvm-project/pull/148334
More information about the cfe-commits
mailing list