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
2018-11-07 Richard Biener <rguenther@suse.de>
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
torture
/
pr68184.C
blob
d0c7c84910ce502230f0ab69d9f94e4c94369e64
1
// { dg-do run }
2
namespace {
3
struct IFoo { virtual void foo() = 0; };
4
struct IBar { virtual void bar() = 0; };
5
6
struct FooBar : private IBar, private IFoo
7
{
8
void call_foo()
9
{
10
try
11
{
12
static_cast<IFoo*>(this)->foo();
13
}
14
catch( ... ) {}
15
}
16
void foo() { throw 1; }
17
void bar() {}
18
};
19
20
void test()
21
{
22
FooBar foobar;
23
foobar.call_foo();
24
}
25
}
26
int main()
27
{
28
test();
29
return 0;
30
}
31