summaryrefslogtreecommitdiff
path: root/clang/test/Driver/exceptions.m
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/Driver/exceptions.m')
-rw-r--r--clang/test/Driver/exceptions.m19
1 files changed, 19 insertions, 0 deletions
diff --git a/clang/test/Driver/exceptions.m b/clang/test/Driver/exceptions.m
new file mode 100644
index 0000000..9b747bb
--- /dev/null
+++ b/clang/test/Driver/exceptions.m
@@ -0,0 +1,19 @@
+// RUN: %clang -target x86_64-apple-darwin9 \
+// RUN: -fsyntax-only -fno-exceptions %s
+
+void f1() {
+ @throw @"A";
+}
+
+void f0() {
+ @try {
+ f1();
+ } @catch (id x) {
+ ;
+ }
+}
+
+int main() {
+ f0();
+ return 0;
+}