Skip to content

Commit

Permalink
added support for FunctionTemplateDecl when resolving type-parameter-…
Browse files Browse the repository at this point in the history
…n-m issues
  • Loading branch information
fosterbrereton committed Nov 22, 2018
1 parent aa9d193 commit 439d6d6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion matchers/utilities.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -568,11 +568,12 @@ std::string PostProcessTypeParameter(const clang::Decl* decl, std::string type)
};

ForEachParent(decl, [&](const Decl* parent) {
// REVISIT (fbrereto) : Gotta do this for FunctionTemplateDecl, and ClassTemplateDecl
if (auto* ctpsd = dyn_cast_or_null<ClassTemplatePartialSpecializationDecl>(parent)) {
iterate_template_params(*ctpsd->getTemplateParameters());
} else if (auto* ctd = dyn_cast_or_null<ClassTemplateDecl>(parent)) {
iterate_template_params(*ctd->getTemplateParameters());
} else if (auto* ftd = dyn_cast_or_null<FunctionTemplateDecl>(parent)) {
iterate_template_params(*ftd->getTemplateParameters());
}
});

Expand Down

0 comments on commit 439d6d6

Please # to comment.