summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/deduction.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2017-01-04 02:03:39 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2017-01-04 02:03:39 +0000
commit6298b44448c9edf852694d2bb9ed35c04325b098 (patch)
treece76aea09a382cf205961678d48472d5f891fde6 /clang/test/SemaTemplate/deduction.cpp
parentb2ca1b3f376b8c903c2249be67405cd4f48f5d53 (diff)
downloadbcm5719-llvm-6298b44448c9edf852694d2bb9ed35c04325b098.tar.gz
bcm5719-llvm-6298b44448c9edf852694d2bb9ed35c04325b098.zip
Remove accidentally-added lines in r290923 test, and add another testcase.
llvm-svn: 290926
Diffstat (limited to 'clang/test/SemaTemplate/deduction.cpp')
-rw-r--r--clang/test/SemaTemplate/deduction.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/clang/test/SemaTemplate/deduction.cpp b/clang/test/SemaTemplate/deduction.cpp
index fdf21bc79a5..5695cab9a27 100644
--- a/clang/test/SemaTemplate/deduction.cpp
+++ b/clang/test/SemaTemplate/deduction.cpp
@@ -385,8 +385,6 @@ namespace overload_vs_pack {
int n1 = g1(X<int, float>(), f, g); // expected-error {{no matching function}}
int n2 = g2(x<int, float>, f, g); // expected-error {{no matching function}}
- int n3 = g1(X<int, float, double, char>(), f);
- int n4 = g2(x<int, float, double, long>, f);
int &a1 = h1<double>(0); // ok, skip deduction for 'f's, deduce matching value from 'g'
int &a2 = h2<double>(0);
@@ -399,4 +397,13 @@ namespace overload_vs_pack {
template<typename ...T> int partial_deduction_2(void (*...f)(T), ...); // expected-note {{deduced incomplete pack <(no value), double> for template parameter 'T'}}
int pd2 = partial_deduction_2(f, g); // expected-error {{no matching function}}
+
+ namespace cwg_example {
+ void f(char, char);
+ void f(int, int);
+ void x(int, char);
+
+ template<typename T, typename ...U> void j(void(*)(U...), void (*...fns)(T, U));
+ void test() { j(x, f, x); }
+ }
}
OpenPOWER on IntegriCloud