aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp1z/using2.C
blob: 8b8ee7ba638cbbd1ce0e71812e9e8b53839303b1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Test for P0195R2 variadic using.
// { dg-do compile { target c++11 } }
// { dg-options "" }

struct A { void f(); };
struct B { void f(int); };

template <class... Bases> struct C: Bases...
{
  using Bases::f...; // { dg-warning "pack expansion" "" { target c++14_down } }
};

int main()
{
  C<A,B> c;
  c.f();
  c.f(42);
}