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
c++: Fix tree_contains_struct for TRAIT_EXPR
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
opt
/
nothrow1.C
blob
a2215abc249c826da6ae803e832f38098de4533b
1
// Test that the nothrow optimization works properly.
2
// { dg-do compile }
3
// { dg-options "-O -fdump-tree-optimized" }
4
5
extern void blah() throw();
6
7
int i, j, k;
8
9
int main()
10
{
11
try
12
{
13
++i;
14
blah();
15
++j;
16
}
17
catch (...)
18
{
19
return -42;
20
}
21
}
22
23
// The catch block should be optimized away.
24
// { dg-final { scan-tree-dump-times "-42" 0 "optimized" } }