3 enum region
{ oriental
, egyptian
, greek
, etruscan
, roman
};
5 void keepalive(bool *var
) { }
11 typedef region antiquities
;
12 static const bool test
= true;
13 static const int key1
= 5;
16 static antiquities value
;
19 gnu_obj_1(antiquities a
, long l
) {}
23 static bool svar
= true;
29 const bool gnu_obj_1::test
;
30 const int gnu_obj_1::key1
;
31 long gnu_obj_1::key2
= 77;
32 gnu_obj_1::antiquities
gnu_obj_1::value
= oriental
;
37 class gnu_obj_2
: public virtual gnu_obj_1
40 static antiquities value_derived
;
43 gnu_obj_2(antiquities b
): gnu_obj_1(oriental
, 7) { }
47 typename gnu_obj_2
<T
>::antiquities gnu_obj_2
<T
>::value_derived
= etruscan
;
54 typedef region antiquities
;
55 static gnu_obj_2
<int> data
;
58 gnu_obj_3(antiquities b
) { }
62 gnu_obj_2
<int> gnu_obj_3
<T
>::data(etruscan
);
68 // instantiate templates explicitly so their static members will exist
69 template class gnu_obj_2
<int>;
70 template class gnu_obj_2
<long>;
71 template class gnu_obj_3
<long>;
75 gnu_obj_1
test1(egyptian
, 4589);
76 gnu_obj_2
<long> test2(roman
);
77 gnu_obj_3
<long> test3(greek
);
80 test4
.dummy
= test4
.elsewhere
;
83 test1
.method (); // breakpoint: constructs-done