diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-01-06 22:09:05 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-01-06 22:09:05 +0000 |
commit | 21714013498fd84a6e8d5ceb1af5d14b6531cfb5 (patch) | |
tree | 9fa31c0116adfa84abf3f60461798b411394efae | |
parent | 60fad45739b764886f707bd204eae9ecce6db1f2 (diff) |
Add test from PR5913, which has already been fixed
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92863 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp index 167c67d519..19962c5349 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp @@ -50,6 +50,19 @@ void test_f2(int i, const int ci, volatile int vi) { A<volatile int> a2 = f2(vi); } +// PR5913 +template <typename T, int N> +void Foo(const T (&a)[N]) { + T x; + x = 0; +} + +const int a[1] = { 0 }; + +void Test() { + Foo(a); +} + // - The transformed A can be another pointer or pointer to member type that // can be converted to the deduced A via a qualification conversion (4.4). template<typename T> A<T> f3(T * * const * const); |