summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.law/template1.C
blob: 9b5f56f073c5d9cbc4cb2941f9a61227065916b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// { dg-do assemble  }
// GROUPS passed templates

class String {
        char s[100];
};

template <class Element>
class Art {
public:
        Element *data;
        Art() { data=new Element[100]; }
};

template <class Key,class Value>
class Assoc {
public:
        struct KeyValue {
                Key key;
                Value value;
                int filled;
        };

        Art<KeyValue> data;
        int fill;
};

int main() {
        Assoc<String,String> table;
}