aboutsummaryrefslogtreecommitdiff
path: root/test/CFrontend
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2008-04-08 19:31:52 +0000
committerDuncan Sands <baldrick@free.fr>2008-04-08 19:31:52 +0000
commit7497b92c2f3de3f6ae78310d8d1fdc6fc78d42db (patch)
tree3d02b21e4c6e6f655b28dab13e5bdbd0c7061d40 /test/CFrontend
parentc8abfdec84c86d32a84d71d3f476a54f162afbcc (diff)
Check that bodies and calls but not declarations
are marked nounwind when compiling without -fexceptions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49393 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CFrontend')
-rw-r--r--test/CFrontend/2008-04-08-NoExceptions.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/CFrontend/2008-04-08-NoExceptions.c b/test/CFrontend/2008-04-08-NoExceptions.c
new file mode 100644
index 0000000000..257fee23b0
--- /dev/null
+++ b/test/CFrontend/2008-04-08-NoExceptions.c
@@ -0,0 +1,7 @@
+// RUN: %llvmgcc -S -o - %s | grep nounwind | count 2
+// RUN: %llvmgcc -S -o - %s | not grep {declare.*nounwind}
+
+void f(void);
+void g(void) {
+ f();
+}