Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 1 | // RUN: %llvmgxx %s -S -emit-llvm -O2 -o - | ignore grep _Unwind_Resume | \ |
Duncan Sands | e479cce | 2007-08-20 17:14:02 +0000 | [diff] [blame] | 2 | // RUN: wc -l | grep {\[23\]} |
Dan Gohman | f17a25c | 2007-07-18 16:29:46 +0000 | [diff] [blame] | 3 | |
4 | struct One { }; | ||||
5 | struct Two { }; | ||||
6 | |||||
7 | void handle_unexpected () { | ||||
8 | try | ||||
9 | { | ||||
10 | throw; | ||||
11 | } | ||||
12 | catch (One &) | ||||
13 | { | ||||
14 | throw Two (); | ||||
15 | } | ||||
16 | } |