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
FSF GCC merge 02/23/03
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.eh
/
vbase2.C
blob
abf722370d6c4cca14b3c1c211ece8539a8d332c
1
// Origin: Mark Mitchell <mark@codesourcery.com>
2
3
int i;
4
5
struct A
6
{
7
A () { i++; }
8
~A () { i--; }
9
};
10
11
struct B : public virtual A
12
{
13
B () { throw 1; }
14
};
15
16
struct D: public B, virtual public A
17
{
18
};
19
20
void f()
21
{
22
D d;
23
}
24
25
int main ()
26
{
27
try {
28
f();
29
} catch (int) {
30
}
31
32
return i;
33
}
34