Debian Codegraph @

gcc/testsuite/g++.old-deja/g++.law/copy2.C

raw
1 // { dg-do assemble }
2 // GROUPS passed copy-ctors
3 // copy file
4 // From: Vivek Khera <[email protected]>
5 // Date: Mon, 15 Nov 1993 16:02:18 -0500
6 // Subject: g++ 2.5.3 fails to automatically generate default initializer
7 // Message-ID: <[email protected]>
8
9 class String
10 {
11 private:
12 char a[100];
13 int len;
14 public:
15 String();
16 };
17
18 String::String()
19 {
20 len = 0;
21 }
22
23
24 struct List
25 {
26 String item[100];
27 int num_items;
28 // List(); // uncomment this line to let compile work
29 };
30
31 int
32 main(int argc, char **argv)
33 {
34 List a;
35 }