FSF GCC merge 02/23/03
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.jason / 3523.C
blobf47bd7b5bf384d29f36b47c6a9d2b0c1f786a1d1
1 // Build don't link: 
2 // GROUPS passed assignment
3 class ccUnwind 
5 public:
6     virtual ~ccUnwind (); // comment out virtual, and void diag changes
7 };
9 template<class T>
10 class ccHandle : public ccUnwind // similarly comment out inheritance
11 {   
12 public:
13     ccHandle& operator = (const ccHandle& h);
16 class cc_Image;          
18 class ccImage : public ccHandle<cc_Image>
20 public:
21 //  reversing the order of the next two lines changes the diagnostic
22 //  printed about the def of ccDisplay::image 
23     ccImage    (const  ccImage  &);
24     ccImage    (const  cc_Image &);
27 class ccDisplay 
29 public:
30     ccImage img;
31 //ccImage image ( ccImage i) {img = i; return img;}
32 // above line  compiles 
33     ccImage image ( ccImage i) { return img = i;} /* this gets void* error */
38 // vd.C: In method `class ccImage ccDisplay::image (class ccImage)':
39 // vd.C:31: bad argument 1 for function `ccImage::ccImage (const class cc_Image&)' (type was void *)
40 // vd.C:31: in base initialization for class `ccImage'