[clang-tools-extra] [clang-tidy] added `RespectOpaqueTypes` option to `readability-qualified-auto check` (PR #147060)

via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 4 07:59:45 PDT 2025


================
@@ -174,6 +176,21 @@ void QualifiedAutoCheck::registerMatchers(MatchFinder *Finder) {
 
 void QualifiedAutoCheck::check(const MatchFinder::MatchResult &Result) {
   if (const auto *Var = Result.Nodes.getNodeAs<VarDecl>("auto")) {
+    if (RespectOpaqueTypes) {
+      auto DeducedType =
----------------
EugeneZelenko wrote:

Please do not use `auto` if type is not spelled explicitly in same statement or iterator.

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


More information about the cfe-commits mailing list