commit | ff430f6af32468d3b09b66266aef03818230c35f | [log] [tgz] |
---|---|---|
author | Reid Kleckner <reid@kleckner.net> | Wed Mar 20 22:29:42 2013 +0000 |
committer | Reid Kleckner <reid@kleckner.net> | Wed Mar 20 22:29:42 2013 +0000 |
tree | f3dafde7ded4def8b6a3334e6be6b6765615b82f | |
parent | aa5573364b79bf4d85380aaec59cae2eeefcb322 [diff] [blame] |
[ms-cxxabi] Mangle function pointer template arguments correctly Reviewers: rjmccall CC: timurrrr, llvm-commits Differential Revision: http://llvm-reviews.chandlerc.com/D554 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177589 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/CodeGenCXX/mangle-ms-templates.cpp b/test/CodeGenCXX/mangle-ms-templates.cpp index e16fe93..d0e8af4 100644 --- a/test/CodeGenCXX/mangle-ms-templates.cpp +++ b/test/CodeGenCXX/mangle-ms-templates.cpp
@@ -78,3 +78,16 @@ void use() { space::foo(42); } + +// PR13455 +typedef void (*FunctionPointer)(void); + +template <FunctionPointer function> +void FunctionPointerTemplate() { + function(); +} + +void spam() { + FunctionPointerTemplate<spam>(); +// CHECK: "\01??$FunctionPointerTemplate@$1?spam@@YAXXZ@@YAXXZ" +}