repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Small ChangeLog tweak.
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.law
/
dtors4.C
blob
5843bfc1a881f7a1813212cdf80e3027d73740ef
1
// { dg-do run }
2
// GROUPS passed destructors
3
#include <stdio.h>
4
5
int destruct = 2;
6
7
class a {
8
public:
9
char *p;
10
a(){ ; }
11
~a(){ destruct--; if (! destruct) printf ("PASS\n");}
12
};
13
14
a test(){
15
return a();
16
}
17
18
int main(){
19
a ai;
20
21
ai = test();
22
}
23