[clang-tools-extra] [clang-tidy][NFC] Fix misc-const-correctness warnings (10/N) (PR #167127)
Baranov Victor via cfe-commits
cfe-commits at lists.llvm.org
Sat Nov 8 07:54:19 PST 2025
================
@@ -147,18 +148,19 @@ static Matcher<NamedDecl> hasStdIteratorName() {
/// recordDecl(hasStdContainerName()) matches \c vector and \c forward_list
/// but not \c my_vec.
static Matcher<NamedDecl> hasStdContainerName() {
- static StringRef ContainerNames[] = {"array", "deque",
- "forward_list", "list",
- "vector",
+ static const StringRef ContainerNames[] = {
----------------
vbvictor wrote:
We would probably need another matcher for it because `hasAnyName` accept `ArrayRef`
https://github.com/llvm/llvm-project/pull/167127
More information about the cfe-commits
mailing list