================
@@ -319,6 +320,12 @@ class HeaderSearch {
};
llvm::StringMap<LookupFileCacheInfo, llvm::BumpPtrAllocator> LookupFileCache;
+ /// The files that were already considered for the \c -Wshadow-header
+ /// diagnostic, keyed by the spelling of the include that resolved to them.
+ /// Since the set of shadowing candidates depends on the spelling, the same
+ /// file has to be considered once per spelling it was found under.
+ llvm::StringMap<llvm::DenseSet<const FileEntry *>> ShadowCheckedHeaders;
----------------
Jinjie-Huang wrote:
Using SmallPtrSet seems preferable, because for most cases, a spelling usually
corresponds to the same FileEntry, meaning the set size is just 1.
https://github.com/llvm/llvm-project/pull/216748
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits