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
Clean up some minor white space issues in trans-decl.c and trans-expr.c
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
eh
/
uncaught4.C
blob
227d11b330bbb35cc6e72a13b9cabe816bc0f84f
1
// PR c++/41174
2
// { dg-do run }
3
4
#include <exception>
5
6
#define assert(E) if (!(E)) __builtin_abort();
7
8
struct e {
9
e()
10
{
11
assert( !std::uncaught_exception() );
12
try {
13
throw 1;
14
} catch (int i) {
15
assert( !std::uncaught_exception() );
16
throw;
17
}
18
}
19
};
20
21
int main()
22
{
23
try {
24
throw e();
25
} catch (int i) {
26
assert( !std::uncaught_exception() );
27
}
28
assert( !std::uncaught_exception() );
29
}