diff options
author | Anders Carlsson <andersca@mac.com> | 2009-09-17 03:46:43 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2009-09-17 03:46:43 +0000 |
commit | df644fb773ed4fb8020208765b2fdcc52da46518 (patch) | |
tree | 390fe4067c8c2e2b78bca8fa4b4e66167e0f82d3 /clang/test/CodeGenCXX/function-template-specialization.cpp | |
parent | 98e00bb162e7aa3052c200b87180509687ad7b2f (diff) | |
download | bcm5719-llvm-df644fb773ed4fb8020208765b2fdcc52da46518.tar.gz bcm5719-llvm-df644fb773ed4fb8020208765b2fdcc52da46518.zip |
When mangling function template specialization, mangle the type encoding of the original function template. Also, port mangle.cpp and function-template-specialization.cpp over to using FileCheck.
llvm-svn: 82114
Diffstat (limited to 'clang/test/CodeGenCXX/function-template-specialization.cpp')
-rw-r--r-- | clang/test/CodeGenCXX/function-template-specialization.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/clang/test/CodeGenCXX/function-template-specialization.cpp b/clang/test/CodeGenCXX/function-template-specialization.cpp index 1efb857192b..e189f5dc735 100644 --- a/clang/test/CodeGenCXX/function-template-specialization.cpp +++ b/clang/test/CodeGenCXX/function-template-specialization.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -emit-llvm %s -o %t && +// RUN: clang-cc -emit-llvm %s -o %t && FileCheck %s --input-file=%t template<typename T, typename U> T* next(T* ptr, const U& diff); @@ -9,10 +9,11 @@ T* next(T* ptr, const U& diff) { void test(int *iptr, float *fptr, int diff) { // FIXME: should be "_Z4nextIiiEPT_S1_RKT0_" - // RUN: grep "_Z4nextIiiEPiS_RKi" %t && + // CHECK: _Z4nextIiiEPT_S0_RKT0_ iptr = next(iptr, diff); // FIXME: should be "_Z4nextIfiEPT_S1_RKT0_" - // RUN: grep "_Z4nextIfiEPfS_RKi" %t && + // CHECK: _Z4nextIfiEPT_S0_RKT0_ + fptr = next(fptr, diff); } @@ -22,6 +23,6 @@ T* next(T* ptr, const U& diff); void test2(int *iptr, double *dptr, int diff) { iptr = next(iptr, diff); // FIXME: should be "_Z4nextIdiEPT_S1_RKT0_" - // RUN: grep "_Z4nextIdiEPdS_RKi" %t + // RUN: grep "_Z4nextIiiEPT_S0_RKT0_" %t dptr = next(dptr, diff); } |