c++: robustify testcase [PR109752]
[official-gcc.git] / gcc / testsuite / g++.dg / cpp1y / lambda-generic-variadic21.C
blobaffb1ffd4742491cd83e9bf6a330d200416c2a18
1 // PR c++/91104
2 // { dg-do run { target c++14 } }
4 void
5 test (void (*f)(int, int, int))
7   f(1, 2, 3);
10 void
11 check (int a, int b, int c)
13   if (a != 1 || b != 2 || c != 3)
14     __builtin_abort ();
17 int
18 main ()
20   test ([](auto... args) {
21     check (args...);
22   });
23   test ([](int a, int b, int c) {
24     check (a, b, c);
25   });