Skip to content

Commit 7fb553f

Browse files
committed
Code to generate function template specializations should support methods as well
1 parent 51f06fd commit 7fb553f

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/CppParser/Parser.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1630,9 +1630,10 @@ FunctionTemplate* Parser::WalkFunctionTemplate(const clang::FunctionTemplateDecl
16301630

16311631
for (auto&& FD : TD->specializations())
16321632
{
1633-
auto F = new Function();
1634-
HandleDeclaration(FD, F);
1635-
WalkFunction(FD, F);
1633+
if (auto MD = dyn_cast<CXXMethodDecl>(FD))
1634+
WalkMethodCXX(MD);
1635+
else
1636+
WalkFunction(FD);
16361637
}
16371638

16381639
return FT;

0 commit comments

Comments
 (0)