summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.other/dtor3.C
blob: f5a00ed577c0c39f8ef57c05d4f00b877bcbff84 (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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// { dg-do assemble  }

struct S1
{
  ~S1(int); // { dg-error "" } destructors may not have parameters
};


template <class T>
struct S2
{
  ~S2(int); // { dg-error "" } destructors may not have parameters
};


struct S3 
{
  ~S3(double) {} // { dg-error "" } destructors may not have parameters
};


template <class T>
struct S4
{
  ~S4(double) {} // { dg-error "" } destructors may not have parameters
};


struct S5
{
  ~S5(); 
};

S5::~S5(float)  // { dg-error "" } destructors may not have parameters
{
}


template <class T>
struct S6
{
  ~S6();
};

template <class T>
S6<T>::~S6(float)   // { dg-error "" } destructors may not have parameters
{
}