[PATCH] D114251: [AST] Add a sugar type for types found via UsingDecl

Sam McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 8 05:40:43 PST 2021


sammccall marked an inline comment as done.
sammccall added a comment.

Thanks Dave!

A last ping in case @rsmith has opinions here as clang owner. Otherwise I'd probably land this in a week or so.



================
Comment at: clang/include/clang/AST/RecursiveASTVisitor.h:2106
+        TRY_TO(TraverseDecl(Child));
+    }
   }
----------------
davrec wrote:
> So the idea is, the UsingDecl which introduced the shadows will have already been traversed within its DeclStmt via the body traversal, but not the UsingShadowDecls it introduced?  Nicely spotted.
That's right, they're not children of the body because CompoundStmt is not DeclContext.

This bug seems to have existed for a long time, but this change caused it to be uncovered in existing clang-tidy tests.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D114251/new/

https://reviews.llvm.org/D114251



More information about the cfe-commits mailing list