[clang-tools-extra] [clang-tidy] Update llvmlibc-implementation-in-namespace to new rules (PR #66504)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 15 11:56:33 PDT 2023
================
@@ -29,16 +31,19 @@ void ImplementationInNamespaceCheck::check(
if (!Result.SourceManager->isInMainFile(MatchedDecl->getLocation()))
return;
- if (const auto *NS = dyn_cast<NamespaceDecl>(MatchedDecl)) {
- if (NS->getName() != RequiredNamespace) {
- diag(NS->getLocation(), "'%0' needs to be the outermost namespace")
- << RequiredNamespace;
- }
+ if (auto *NS = dyn_cast<NamespaceDecl>(MatchedDecl)) {
----------------
EugeneZelenko wrote:
`const auto *`
https://github.com/llvm/llvm-project/pull/66504
More information about the cfe-commits
mailing list