From f4dccf115cc198e552b520fda0ee623457015db7 Mon Sep 17 00:00:00 2001 From: Bruno Ricci Date: Tue, 11 Aug 2020 15:54:15 +0100 Subject: [PATCH] [clang] Add a matcher for template template parameters. There are already matchers for type template parameters and non-type template parameters, but somehow no matcher exists for template template parameters and I need it to write unit tests. Differential Revision: https://reviews.llvm.org/D85536 Reviewed By: aaron.ballman --- clang/include/clang/ASTMatchers/ASTMatchers.h | 12 ++++++++++++ clang/lib/ASTMatchers/ASTMatchersInternal.cpp | 3 +++ clang/lib/ASTMatchers/Dynamic/Registry.cpp | 1 + clang/unittests/ASTMatchers/ASTMatchersNodeTest.cpp | 9 +++++++++ 4 files changed, 25 insertions(+) diff --git a/clang/include/clang/ASTMatchers/ASTMatchers.h b/clang/include/clang/ASTMatchers/ASTMatchers.h index e37c68a8f156..f5c4fe63182f 100644 --- a/clang/include/clang/ASTMatchers/ASTMatchers.h +++ b/clang/include/clang/ASTMatchers/ASTMatchers.h @@ -562,6 +562,18 @@ extern const internal::VariadicDynCastAllOfMatcher templateTypeParmDecl; +/// Matches template template parameter declarations. +/// +/// Given +/// \code +/// template