2
0
mirror of git://gcc.gnu.org/git/gcc.git synced 2025-04-18 01:20:48 +08:00

Add testcase of PR c++/90448, already fixed in trunk.

PR c++/90448
	* g++.dg/cpp1y/lambda-generic-variadic20.C: New.
This commit is contained in:
Paolo Carlini 2020-04-22 18:05:18 +02:00
parent 203f2b73e2
commit 183e9006cc
2 changed files with 21 additions and 0 deletions
gcc/testsuite

@ -1,3 +1,8 @@
2020-04-22 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/90448
* g++.dg/cpp1y/lambda-generic-variadic20.C: New.
2020-04-22 Martin Sebor <msebor@redhat.com>
PR middle-end/94647

@ -0,0 +1,16 @@
// PR c++/90448
// { dg-do compile { target c++14 } }
template<class ... Ts> int fooV(Ts ... ts) {
auto L = [](auto ... a) {
auto M = [](decltype(a) ... b) -> void {
};
return M;
};
decltype(L(L, ts...)) (*fp)(decltype(L), decltype(ts) ...) = L;
return 0;
}
int run2 = fooV("BC", 3, 2.77, 'A', float{}, short{}, unsigned{});