summaryrefslogtreecommitdiffstats
path: root/clang
diff options
context:
space:
mode:
Diffstat (limited to 'clang')
-rw-r--r--clang/lib/AST/MicrosoftMangle.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/AST/MicrosoftMangle.cpp b/clang/lib/AST/MicrosoftMangle.cpp
index 6ce7018be19..8563f2e2911 100644
--- a/clang/lib/AST/MicrosoftMangle.cpp
+++ b/clang/lib/AST/MicrosoftMangle.cpp
@@ -1093,11 +1093,11 @@ void MicrosoftCXXNameMangler::mangleTemplateArg(const TemplateDecl *TD,
if (const FieldDecl *FD = dyn_cast<FieldDecl>(ND)) {
mangleMemberDataPointer(cast<CXXRecordDecl>(FD->getParent()), FD);
} else if (const FunctionDecl *FD = dyn_cast<FunctionDecl>(ND)) {
- const CXXMethodDecl *MD = dyn_cast<CXXMethodDecl>(ND);
+ const CXXMethodDecl *MD = dyn_cast<CXXMethodDecl>(FD);
if (MD && MD->isInstance())
mangleMemberFunctionPointer(MD->getParent(), MD);
else
- mangle(ND, "$1?");
+ mangle(FD, "$1?");
} else {
mangle(ND, TA.isDeclForReferenceParam() ? "$E?" : "$1?");
}
OpenPOWER on IntegriCloud