1// RUN: %clang_cc1 -fcxx-exceptions -fexceptions -emit-llvm-only -verify %s -Wno-unreachable-code
2
3int val = 42;
4int& test1() {
5  return throw val, val;
6}
7
8int test2() {
9  return val ? throw val : val;
10}
11
12// rdar://problem/8608801
13void test3() {
14  throw false;
15}
16
17// PR10582
18int test4() {
19  return 1 ? throw val : val;
20}
21