summaryrefslogtreecommitdiffstats
path: root/test/SemaTemplate/deduction.cpp
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2015-01-18 16:23:48 +0000
committerdim <dim@FreeBSD.org>2015-01-18 16:23:48 +0000
commitc86b984ea8ecb3e944dc3de48539f4c1f65851ea (patch)
tree3eb853da77d46cc77c4b017525a422f9ddb1385b /test/SemaTemplate/deduction.cpp
parentc696171ff15f0ee60dea4abfd99a135473c95656 (diff)
downloadFreeBSD-src-c86b984ea8ecb3e944dc3de48539f4c1f65851ea.zip
FreeBSD-src-c86b984ea8ecb3e944dc3de48539f4c1f65851ea.tar.gz
Vendor import of clang RELEASE_360/rc1 tag r226102 (effectively, 3.6.0 RC1):
https://llvm.org/svn/llvm-project/cfe/tags/RELEASE_360/rc1@226102
Diffstat (limited to 'test/SemaTemplate/deduction.cpp')
-rw-r--r--test/SemaTemplate/deduction.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/test/SemaTemplate/deduction.cpp b/test/SemaTemplate/deduction.cpp
index e942289..c59f10d 100644
--- a/test/SemaTemplate/deduction.cpp
+++ b/test/SemaTemplate/deduction.cpp
@@ -107,7 +107,7 @@ namespace PR7463 {
}
namespace test0 {
- template <class T> void make(const T *(*fn)()); // expected-note {{candidate template ignored: can't deduce a type for 'T' which would make 'const T' equal 'char'}}
+ template <class T> void make(const T *(*fn)()); // expected-note {{candidate template ignored: can't deduce a type for 'T' that would make 'const T' equal 'char'}}
char *char_maker();
void test() {
make(char_maker); // expected-error {{no matching function for call to 'make'}}
@@ -191,4 +191,14 @@ namespace PR19372 {
using U = BindBack<Z, int, int>::apply<char>;
using U = Z<char, int, int>;
+
+ namespace BetterReduction {
+ template<typename ...> struct S;
+ template<typename ...A> using X = S<A...>; // expected-note {{parameter}}
+ template<typename ...A> using Y = X<A..., A...>;
+ template<typename ...A> using Z = X<A..., 1, 2, 3>; // expected-error {{must be a type}}
+
+ using T = Y<int>;
+ using T = S<int, int>;
+ }
}
OpenPOWER on IntegriCloud