aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/ext/integer-pack6.C
blob: dc43116128bae24afca499955b77b110cb41629a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// Verify a non-constant argument to __integer_pack respects SFINAE.
// { dg-do compile { target c++11 } }

template<int...> struct A { };

template<class T> auto f(int) -> A<__integer_pack(T::value)...> = delete;
template<class T> void f(...);

struct B { static int value; };

int main() {
  f<B>(0);
}