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
* ru.po: Update.
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.jason
/
byval.C
blob
e09c6ea66405f40f05b8b59c0705f2529d9d4682
1
// { dg-do run }
2
// Bug: a is destroyed in both foo() and main()
3
4
int count;
5
6
struct A {
7
double a,b;
8
A(int) { count++; }
9
A(const A&) { count++; }
10
~A() { count--; }
11
};
12
13
void foo (A a)
14
{ }
15
16
int main()
17
{
18
foo (1);
19
return count;
20
}