summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/template/ctor2.C
blob: 1c8d8a65d9b1740a4154fadedc8e6625e8616762 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// { dg-do run }

int i;

template <class T>
struct S
{
  S () { i = 1; }
};

static S<int> s[1];

int main ()
{
  if (!i)
    return 1;
}