================
@@ -2283,6 +2284,37 @@ using HasOpNameMatcher =
HasOpNameMatcher hasAnyOperatorNameFunc(ArrayRef<const StringRef *> NameRefs);
+/// Matches nodes of type T (CompoundStmt or StmtExpr) that contain a sequence
+/// of consecutive substatements matching the provided matchers in order.
+///
+/// See \c hasAdjacentSubstatements() in ASTMatchers.h for details.
+template <typename T, typename ArgT = std::vector<Matcher<Stmt>>>
+class HasAdjSubstatementsMatcher : public MatcherInterface<T> {
----------------
vbvictor wrote:
I think it hurts readability for us as developers.
E.g., now in comments it points to `hasAdjacentSubstatements` which is a little
confusing. I believe it's very valuable to be able to find the implementation
of matcher by concatenating its name and the `Matcher` suffix.
The same logic works for names of clang-tidy check classes.
https://github.com/llvm/llvm-project/pull/169965
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits