[clang] [clang-tools-extra] [llvm] [clang] Introduce diagnostics suppression mappings (PR #112517)

Boaz Brickner via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 4 06:21:14 PST 2024


================
@@ -477,6 +486,118 @@ void DiagnosticsEngine::setSeverityForAll(diag::Flavor Flavor,
       setSeverity(Diag, Map, Loc);
 }
 
+namespace {
+class WarningsSpecialCaseList : public llvm::SpecialCaseList {
+public:
+  static std::unique_ptr<WarningsSpecialCaseList>
+  create(const llvm::MemoryBuffer &MB, std::string &Err) {
----------------
bricknerb wrote:

Avoid putting the implementation in an anonymous namespace.
Per https://llvm.org/docs/CodingStandards.html#anonymous-namespaces, we should only put the class declaration into anonymous namespace.

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


More information about the cfe-commits mailing list