jcking1034 added inline comments.

================
Comment at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:1409
   return BindableMatcher<T>(
-      makeAllOfComposite(InnerMatchers).template dynCastTo<T>());
+      makeAllOfComposite(InnerMatchers).template dynCastTo<T>(),
+      makeMatcherNameFromType<InnerT>());
----------------
jcking1034 wrote:
> @ymandel suggested an alternate implementation where we instead pass the 
> matcher name to `makeAllOfComposite`, which then passes the name to 
> `constructVariadic`, to avoid making changes to `BindableMatcher`. I may look 
> into this again, but my previous attempts to try this approach seemed messy 
> due to the fact that these functions are used in a few different places, and 
> because `makeAllOfComposite` handles cases with 0 or 1 inner matchers without 
> constructing a variadic matcher.
Following up on this, I've gone ahead and implemented @ymandel 's approach, as 
the original implementation led to some issues with `getName` returning the 
wrong name.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D113917

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to