summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2018-02-20 23:47:12 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2018-02-20 23:47:12 +0000
commit799049fee5238acec7f3d737ea968ede1978cfe6 (patch)
tree9c2e0d0e9cb7f39e3f612a33c4b7ebad7a9cc485 /test
parentb2456f4e1140058e138f783176b44d2fa648e247 (diff)
downloadclang-799049fee5238acec7f3d737ea968ede1978cfe6.tar.gz
Fix assert when template argument deduction's original call arg checking triggers class template instantiation.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@325646 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/SemaTemplate/temp_arg_pack.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/SemaTemplate/temp_arg_pack.cpp b/test/SemaTemplate/temp_arg_pack.cpp
new file mode 100644
index 0000000000..b79dca78bc
--- /dev/null
+++ b/test/SemaTemplate/temp_arg_pack.cpp
@@ -0,0 +1,8 @@
+// RUN: %clang_cc1 -verify %s
+
+namespace deduce_pack_non_pack {
+ template <typename...> class A;
+ template <typename> struct C {};
+ template <typename T> void g(C<A<T>>); // expected-note {{candidate template ignored: deduced type 'C<A<[...], (no argument)>>' of 1st parameter does not match adjusted type 'C<A<[...], int>>' of argument [with T = bool]}}
+ void h(C<A<bool, int>> &x) { g(x); } // expected-error {{no matching function}}
+}