summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/mangle.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2011-04-24 08:43:07 +0000
committerJohn McCall <rjmccall@apple.com>2011-04-24 08:43:07 +0000
commitc0a455942453a37dd7db83eb354f40a49872ab06 (patch)
tree71f966cb74f66c544f22b7523a69b2fb750e9a2c /test/CodeGenCXX/mangle.cpp
parenta0ce15c13a69c430d8980a1fcf03f420855c18ca (diff)
GCC seems to create address-of expression manglings when passing *any*
function as a template argument where a pointer to function is wanted. Just extend the existing hack. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130084 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/mangle.cpp')
-rw-r--r--test/CodeGenCXX/mangle.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/CodeGenCXX/mangle.cpp b/test/CodeGenCXX/mangle.cpp
index 2e1229c2cc..05cc5587e1 100644
--- a/test/CodeGenCXX/mangle.cpp
+++ b/test/CodeGenCXX/mangle.cpp
@@ -664,3 +664,15 @@ namespace test24 {
foo();
}
}
+
+// rdar://problem/8806641
+namespace test25 {
+ template <void (*fn)()> struct A {
+ static void call() { fn(); }
+ };
+ void foo();
+ void test() {
+ // CHECK: call void @_ZN6test251AIXadL_ZNS_3fooEvEEE4callEv()
+ A<foo>::call();
+ }
+}