[clang-tools-extra] [clang][include-cleaner] Support ObjC @selector expressions in WalkAST (PR #212564)

Nico Weber via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 12 22:11:38 PDT 2026


================
@@ -38,6 +41,14 @@ class NamedDecl;
 class SourceLocation;
 namespace include_cleaner {
 
+using ObjCSelectorMap =
+    llvm::DenseMap<Selector, llvm::SmallVector<NamedDecl *, 2>>;
+
+/// Builds a map from Objective-C Selectors to their declarations in the given
+/// ASTContext.
+/// This is used to optimize selector lookups during AST walking.
----------------
nico wrote:

very nit: s/optimize/do/

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


More information about the cfe-commits mailing list