diff options
author | John McCall <rjmccall@apple.com> | 2011-04-24 08:43:07 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2011-04-24 08:43:07 +0000 |
commit | 617339e6923d8ca0536cc819c3c665a5799790cc (patch) | |
tree | 732452b8ab17d3058946d2d1126041b9595381c6 /clang/test/CodeGenCXX/mangle.cpp | |
parent | 6dc0a2b4677c6c913585d2ce4d8f05359c975c36 (diff) | |
download | bcm5719-llvm-617339e6923d8ca0536cc819c3c665a5799790cc.tar.gz bcm5719-llvm-617339e6923d8ca0536cc819c3c665a5799790cc.zip |
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.
llvm-svn: 130084
Diffstat (limited to 'clang/test/CodeGenCXX/mangle.cpp')
-rw-r--r-- | clang/test/CodeGenCXX/mangle.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/CodeGenCXX/mangle.cpp b/clang/test/CodeGenCXX/mangle.cpp index 2e1229c2ccc..05cc5587e1d 100644 --- a/clang/test/CodeGenCXX/mangle.cpp +++ b/clang/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(); + } +} |