https://github.com/localspook created 
https://github.com/llvm/llvm-project/pull/190094

This is another ad-hoc approach made obsolete by #151035.

>From 1d0026b3c86ae699a8845b496c4dce4f6450d9cf Mon Sep 17 00:00:00 2001
From: Victor Chernyakin <[email protected]>
Date: Sun, 29 Mar 2026 17:26:02 -0700
Subject: [PATCH] [clang-tidy] Remove another ad-hoc exclusion for system
 headers

---
 .../clang-tidy/portability/StdAllocatorConstCheck.cpp      | 7 -------
 1 file changed, 7 deletions(-)

diff --git 
a/clang-tools-extra/clang-tidy/portability/StdAllocatorConstCheck.cpp 
b/clang-tools-extra/clang-tidy/portability/StdAllocatorConstCheck.cpp
index ff58505e8f87c..d82b34e803242 100644
--- a/clang-tools-extra/clang-tidy/portability/StdAllocatorConstCheck.cpp
+++ b/clang-tools-extra/clang-tidy/portability/StdAllocatorConstCheck.cpp
@@ -54,13 +54,6 @@ void StdAllocatorConstCheck::registerMatchers(MatchFinder 
*Finder) {
 
 void StdAllocatorConstCheck::check(const MatchFinder::MatchResult &Result) {
   const auto *T = Result.Nodes.getNodeAs<TypeLoc>("type_loc");
-  if (!T)
-    return;
-  // Exclude TypeLoc matches in STL headers.
-  if (isSystem(Result.Context->getSourceManager().getFileCharacteristic(
-          T->getBeginLoc())))
-    return;
-
   diag(T->getBeginLoc(),
        "container using std::allocator<const T> is a deprecated libc++ "
        "extension; remove const for compatibility with other standard "

_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to