[all-commits] [llvm/llvm-project] 4aacaf: [clang][ASTVisitor] Visit `HoldingVar` from `Bindi...

Clement Courbet via All-commits all-commits at lists.llvm.org
Thu Dec 12 08:02:22 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 4aacafd49b74dc168e0d99018b4c8289ce9c923e
      https://github.com/llvm/llvm-project/commit/4aacafd49b74dc168e0d99018b4c8289ce9c923e
  Author: Clement Courbet <courbet at google.com>
  Date:   2024-12-12 (Thu, 12 Dec 2024)

  Changed paths:
    M clang/include/clang/AST/RecursiveASTVisitor.h
    M clang/unittests/AST/ASTContextParentMapTest.cpp
    M clang/unittests/Analysis/FlowSensitive/TransferTest.cpp

  Log Message:
  -----------
  [clang][ASTVisitor] Visit `HoldingVar` from `BindingDecl`. (#117858)

Tuple-like types introduce `VarDecl`s in the AST for their "holding
vars", but AST visitors do not visit those. As a result the `VarDecl`
for the holding var is orphaned when trying to retreive its parents.

Fix a `FlowSensitive` test that assumes that only a `BindingDecl` is
introduced with the given name (the matcher now can also reach the
`VarDecl` for the holding var).



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list