From 03bd40c39817cddb4dabb7a2b1bf0037ff51a93c Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Thu, 10 Sep 2026 22:14:25 +0000 Subject: [PATCH] Disable clang-tidy forbidding forward decls of classes with the same name in another namespace (#7766) --- .clang-tidy | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.clang-tidy b/.clang-tidy index 7164b472ee3c..96d81e23bdce 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -51,6 +51,9 @@ Checks: # Finds issues like out-of-memory in main(). We don't use exceptions, so it's # unlikely to find real issues. - '-bugprone-exception-escape' + # We have File class types in different namespaces and we forward declare it, + # but don't find this to be problematic. + - '-bugprone-forward-declaration-namespace' # Doesn't respect `[[clang::enum_extensibility(open)]]`. - '-bugprone-invalid-enum-default-initialization' # Has false positives in places such as using an argument to declare a name,