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
Dead
[official-gcc.git]
/
gomp-20050608-branch
/
gcc
/
testsuite
/
g++.old-deja
/
g++.other
/
dtor8.C
blob
5f2071d5a79753524584c69373c7954bd97e963f
1
// { dg-do run }
2
// { dg-options "-O1" }
3
// Origin: Mark Mitchell <mark@codesourcery.com>
4
5
int result;
6
7
struct S
8
{
9
S ();
10
S (const S&);
11
~S ();
12
13
int i;
14
double d[18];
15
};
16
17
S* s;
18
19
S::S ()
20
{
21
s = this;
22
}
23
24
S::~S ()
25
{
26
if (s != this)
27
result = 1;
28
}
29
30
inline S f ()
31
{
32
return S ();
33
}
34
35
int main ()
36
{
37
f ();
38
return result;
39
}