aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/Mangle.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-09-26 20:13:56 +0000
committerAnders Carlsson <andersca@mac.com>2009-09-26 20:13:56 +0000
commit1668f2062b237ddb137f5d16388b3dea49651f85 (patch)
treefb3f9b6bdac354f24a8ed3316a6ab8f3ff727961 /lib/CodeGen/Mangle.cpp
parent0fa6df440023a95d8b47c79111e8613fc29f723b (diff)
Don't crash when trying to mangle function templates.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82872 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/Mangle.cpp')
-rw-r--r--lib/CodeGen/Mangle.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/Mangle.cpp b/lib/CodeGen/Mangle.cpp
index 69e73e78c0..e07c38fd11 100644
--- a/lib/CodeGen/Mangle.cpp
+++ b/lib/CodeGen/Mangle.cpp
@@ -335,7 +335,7 @@ void CXXNameMangler::mangleUnscopedTemplateName(const TemplateDecl *ND) {
if (mangleSubstitution(ND))
return;
- mangleUnscopedName(ND);
+ mangleUnscopedName(ND->getTemplatedDecl());
addSubstitution(ND);
}
@@ -532,7 +532,7 @@ void CXXNameMangler::mangleTemplatePrefix(const TemplateDecl *ND) {
// FIXME: <substitution> and <template-param>
manglePrefix(ND->getDeclContext());
- mangleUnqualifiedName(ND);
+ mangleUnqualifiedName(ND->getTemplatedDecl());
}
void